Dec 19, 2008 at 5:26 PM
Join Date: Jan 4, 2008
Location: Lingerie, but also, like, fancy curtains
Posts: 3052
Hey guys,
Yesterday, I started working on some new weapons, but the weapon code was fairly annoying, so I decided to edit some TSC commands.
For instance, ML+ now doubles your current health.
This may seem a tad boring, but I found something interestiong while I was doing this.
The interesting thing being:
http://img152.imageshack.us/my.php?image=wrongbp8.png
So what was the interesting thing again?
Well, as most of you know, once you get over 256 health, the health bar overflows. Here, I have 9999 health, and the health bar hasn't overflowed yet!
In case you wanted the command I made, here it is:
And that's at offset 419CB0.
I know this isn't very threadworthy, but I'll post any other things I find here.
Cheers!
Lace
Edit:
A while back, I think I posted this:
None of these values had actually been tested, and when I tried to actually edit a weapon using these, nothing happened, not even when I deleted all of the code.
A call to snake level 1 is made in 409053, so I just changed the
To another value on the list.
0x000043f0 is not snake level 2, but rather, snake level 3, and 0x000047b0
is a weapon that shouldn't exist.
It is 100% invisible, travels almost instantaneously, and goes through walls.
The reason it shouldn't exist is because it isn't weapon 0008, which doesn't work at all, or any other weapon, so it is good as free space.
I'll add more values when I find them.
Edity:
This post just keeps getting longer and longer...
Okay, interesting stuff.
I was calling to all the weapon functions through the snake, and I thought that that wouldn't matter, since it's the bullets that have the different properties.
Of course, I was wrong
Most of the weapons looked like the ones in the game, but with a few snake properties as well.
For instance, all weapons traveled through walls, and you couldn't hold x. The missile launcher traveled in wavy lines, and the bubbler went twice as far.
Some of these anomolies make sense, like that you can't hold down x. This function would be handled elsewhere.
But some things, like the going through walls, and especially the variation inw hich snake traits they have, are quite strange indeed.
Edit...
Okay, found out about the missile launcher. It turns out that it was being wavy because it was level 3, and not level one, that I edited. The reason there was only one on the screen was because the snake didn't fire three at once.
What I'm doing here is taking a gun, and filling it with another guns ammo, not everything is changed.
On a related note, anyone know where the offset for the firing mechanism (gun) is?
Gads, if someone doesn't read this soon, This post will destroy the page.
One... More... edit...
Found out what the values lead to.
Note that there are a few holes, not every weapon is there.
Gawds, another edit.
Here's how you would do ML-
Yesterday, I started working on some new weapons, but the weapon code was fairly annoying, so I decided to edit some TSC commands.
For instance, ML+ now doubles your current health.
This may seem a tad boring, but I found something interestiong while I was doing this.
The interesting thing being:
http://img152.imageshack.us/my.php?image=wrongbp8.png
So what was the interesting thing again?
Well, as most of you know, once you get over 256 health, the health bar overflows. Here, I have 9999 health, and the health bar hasn't overflowed yet!
In case you wanted the command I made, here it is:
Code:
push ebp ;random TSC function that replaces ML+
mov ebp,esp ;good practrice to store the TSC var.
mov ecx,[0049E6CC] ;moves the current health into ecx,
add ecx,ecx ;doubles it,
mov [0049E6D0],ecx ;and makes it the max health
mov [0049E6CC],ecx ;and current health
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
pop ebp
ret
And that's at offset 419CB0.
I know this isn't very threadworthy, but I'll post any other things I find here.
Cheers!
Lace
Edit:
A while back, I think I posted this:
Snake: 0x00004160, 0x000043f0, 0x000047b0
Polar Star: 0x00004b30, 0x00005120, 0x000055a0
Fireball: 0x00005d80, 0x00005f30, 0x00006190
Machine Gun: 0x000064d0, 0x000068b0, 0x000075e0
Missile Launcher: 0x000078a0, 0x00006bb0, 0x00006e60
Bubbler: 0x00007110, 0x00007910, 0x00008080
Blade: 0x00008230, 0x00008710, 0x00008ae0
Super Missile Launcher: 0x00008230, 0x00008f40, 0x00008f90
None of these values had actually been tested, and when I tried to actually edit a weapon using these, nothing happened, not even when I deleted all of the code.
A call to snake level 1 is made in 409053, so I just changed the
Code:
call 00404160
0x000043f0 is not snake level 2, but rather, snake level 3, and 0x000047b0
is a weapon that shouldn't exist.
It is 100% invisible, travels almost instantaneously, and goes through walls.
The reason it shouldn't exist is because it isn't weapon 0008, which doesn't work at all, or any other weapon, so it is good as free space.
I'll add more values when I find them.
Edity:
This post just keeps getting longer and longer...
Okay, interesting stuff.
I was calling to all the weapon functions through the snake, and I thought that that wouldn't matter, since it's the bullets that have the different properties.
Of course, I was wrong
Most of the weapons looked like the ones in the game, but with a few snake properties as well.
For instance, all weapons traveled through walls, and you couldn't hold x. The missile launcher traveled in wavy lines, and the bubbler went twice as far.
Some of these anomolies make sense, like that you can't hold down x. This function would be handled elsewhere.
But some things, like the going through walls, and especially the variation inw hich snake traits they have, are quite strange indeed.
Edit...
Okay, found out about the missile launcher. It turns out that it was being wavy because it was level 3, and not level one, that I edited. The reason there was only one on the screen was because the snake didn't fire three at once.
What I'm doing here is taking a gun, and filling it with another guns ammo, not everything is changed.
On a related note, anyone know where the offset for the firing mechanism (gun) is?
Gads, if someone doesn't read this soon, This post will destroy the page.
One... More... edit...
Found out what the values lead to.
Note that there are a few holes, not every weapon is there.
Snake:
0x00004160 - Snake Level 1
0x000043f0 - Snake Level 3
Fireball:
0x00004b30 - Fireball level 3
Missile Launcher:
0x000055A0 - Missile Launcher Level 3
Super Missile Launcher:
0x00007910 - Super Missile Level 3
Spur:
0x00008710 - Spur All Levels?
Weapon 0008:
0x00005D80 - Weapon 0008 Level 1
0x000078a0 - Weapon 0008 Level 2
0x00008080 - Weapon 0008 Level 3
0x00008ae0 - Weapon 0008 Level 4
0x00008f90 - Weapon 0008 Level 5
Bubbler:
0x00005f30 - Bubbler Level 1
0x00006190 - Bubbler Level 2
0x000064d0 - Bubbler Level 3
0x000068b0 - Thorn
Blade:
0x00006bb0 - Blade Level 1
0x00006e60 - Blade Level 2
0x00007110 - Blade Level 3
0x000075e0 - Blade Slashes
Unknown:
0x000047b0 - Invisible Instant 1
0x00008230 - Invisible Instant 2
0x00008f40 - Invisible Instant 3
0x00005120 - Stay Pop
Gawds, another edit.
Here's how you would do ML-
Code:
push ebp ;ML-
mov ebp,esp ;stores the TSC var
mov ecx,[0049E6D0] ;stores the max health
sub ecx,[ebp+0008] ;subracts the TSC var from it
mov [0049E6CC],ecx ;and makes it the current health
mov [0049E6D0],ecx ;and the max health
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
pop ebp
ret