Weapon Hacking

Nov 29, 2007 at 6:45 AM
Luls
"Bleep, Bloop, Bleep, Bloop"
Join Date: Oct 6, 2007
Location: I dunnos
Posts: 1584
jcys810 said:
@Turska
-Sorry for the dumb question, but what are the fade out animations for?

For... animations to fade out......
 
Nov 29, 2007 at 7:48 AM
Justin-chan
"Heavy swords for sale. Suitable for most RPG Protagonists. Apply now!"
Join Date: Oct 15, 2007
Location: Nowhere
Posts: 1921
Age: 30
Do the animations even fade out? Don't notice it.
 
Nov 29, 2007 at 11:46 AM
Junior Member
"Wow! The more I drink of this magical beverage, the more games I can play! Wheee!"
Join Date: Jul 15, 2007
Location:
Posts: 29
'Fade out animation' might not be the correct word to describe it, but the image below is hopefully more clear.
diph.php

The fade out animation takes place when the shot reaches its maximum range while still having penetrating power (that is, the shot didn't hit a wall or an enemy).
 
Nov 29, 2007 at 12:47 PM
Hoxtilicious
"Life begins and ends with Nu."
Join Date: Dec 30, 2005
Location: Germany
Posts: 3218
Age: 32
jcys810 said:
0x0C - Rect A1 (X Axis of smoke/explosion)
0x10 - Rect A2 (Y Axis of smoke/explosion)
0x14 - Rect A3 (X Axis probably, smoke effects vanish? Possibility of it hiding behind solid)
0x18 - Rect A4 (Y Axis of smoke effects hide behind solid)

Thats wrong :x
Its Rect A1, Rect A2, B1 and Rect B2
 
Nov 29, 2007 at 5:31 PM
Justin-chan
"Heavy swords for sale. Suitable for most RPG Protagonists. Apply now!"
Join Date: Oct 15, 2007
Location: Nowhere
Posts: 1921
Age: 30
turska said:
'Fade out animation' might not be the correct word to describe it, but the image below is hopefully more clear.
diph.php

The fade out animation takes place when the shot reaches its maximum range while still having penetrating power (that is, the shot didn't hit a wall or an enemy).
Oh. The collision effect eh.
SP said:
Thats wrong :x
Its Rect A1, Rect A2, B1 and Rect B2
Really? That means I must have gotten my values mixed up. o.o
 
Nov 30, 2007 at 11:10 AM
Luls
"Bleep, Bloop, Bleep, Bloop"
Join Date: Oct 6, 2007
Location: I dunnos
Posts: 1584
jcys810 said:
Really? That means I must have gotten my values mixed up. o.o

o.o

Which means...?
 
Nov 30, 2007 at 1:00 PM
Been here way too long...
"What're YOU lookin' at?"
Join Date: Jan 21, 2007
Location:
Posts: 1111
That he got the values mixed up...?
 
Nov 30, 2007 at 5:19 PM
Luls
"Bleep, Bloop, Bleep, Bloop"
Join Date: Oct 6, 2007
Location: I dunnos
Posts: 1584
oh........

o.o
 
Dec 1, 2007 at 9:11 PM
Senior Member
"This is the greatest handgun ever made! You have to ask yourself, do I feel lucky?"
Join Date: May 4, 2006
Location: Florida
Posts: 115
Age: 43
I'm not sure if this has been posted elsewhere since it seems like people are talking about hit boxes and stuff but here's what I've found just recently using the polar star as a test weapon:

flag 0x20 - destroy breakable bricks
flag 0x40 - pierce through breakable bricks

For some reason when flag 0x04 is set I can't get the polar star to destroy any breakable blocks.

0x0C - entity collision bullet width
0x10 - entity collision bullet height
0x14 - wall collision bullet width
0x18 -wall collision bullet height

0x1C - bullet graphic offset when facing left measured from quote's right side (+left -right). Also used then shooting up.
0x20 - vertical graphic offset from quote's feet when shooting left/right. When shooting up/down its a horizontal shift measured from quote's right side.
0x24 - bullet graphic offset when facing right measured from quote's right side (+left -right). Also used then down.
0x28 - doesn't seem to do anything...

This should help wrap up the bullet part of the FAQ except for graphics.
 
Dec 2, 2007 at 2:39 AM
Senior Member
"Huzzah!"
Join Date: Jun 1, 2007
Location: In Space
Posts: 191
Thanks for the exrea info there, Wistil! I can see some use coming out of at piercing flag (imagine the fireball bouncing along, taking out anything breakable in its path :p )

With changing the fadeout animations, is it theoretically possible to make, say, the fireball explode (like missiles)? It would be kinda neat to change the fireball into a grenade-launcher-ish weapon, though if I did that I would probably need a way to change the amount of fireballs allowed onscreen for each power level. Runelancer changed that, but then again, he was an assembly nut, so... ;P

I wonder... would the machinegun/bubbler's rate of fire and the spur's charge time both be easily changeable (once we find the offsets, that is), or would they be code-dependent and impossible to change without assembly? Now if only we could find that and an easy way to modify projectile speed, I'll be a happy camper.
Or, perhaps, is projectile speed somewhere in npc.tbl? Hmm... :p
 
Dec 2, 2007 at 4:28 AM
Senior Member
"This is the greatest handgun ever made! You have to ask yourself, do I feel lucky?"
Join Date: May 4, 2006
Location: Florida
Posts: 115
Age: 43
The rate of fire, number of projectiles, and projectile speed are most likely inside each weapon's assembly code and not part of the data section of the exe. The projectile speed might be a little difficult to change depending on some weapons (Missiles seem to speed up as time go by). The number of projectiles should be easy enough to change and I'm not sure about the rate of fire.
The big key is figuring out exactly where this data is. I know we have some offsets to the weapon code (I haven't looked at any of these area yet, still working on the editor) but we still need to find a few things to have complete weapon edit abilities.

We need the locations of the gun data. Currently we're messing with the bullet data but somewhere there's data that says the weapon X is level 1 and it upgrades to weapon Y and then to weapon Z. This is how the Polar Star and Spur are allowed to use the same bullet info. It also might have the info as to what graphics to use for which gun too.

We also need the rest of the weapon code offsets. Since the Spur level 2 and level 3 don't seem to have any bullet info, there's got to be a fairly large section of code dedicated to them and without it changing the Spur weapon might be impossible...
 
Dec 2, 2007 at 7:26 AM
Senior Member
"Master using it, and you can have this!"
Join Date: Nov 28, 2007
Location:
Posts: 86
diph.php


ZING!

It's at 1e176, a single byte that defines the number of fireballs plus one at the screen at once; hardcoded into the weapon function as a literal.
Giving it very high values is fruitless because the fireball "fades out" before you can produce the number.
Other weapons also have this test (I've experimented with a 2-shot machine gun... with a crash as sound, haha)

after some more hacking:

diph.php


This is after changing the number of bullets for the machine gun at 1e3d7 (like fireball) and rate of fire to one bullet per tick at 1e459, this defines how many ticks to wait before firing a bullet, also a single byte.

diph.php


It is very fun :p
 
Dec 2, 2007 at 9:44 AM
Justin-chan
"Heavy swords for sale. Suitable for most RPG Protagonists. Apply now!"
Join Date: Oct 15, 2007
Location: Nowhere
Posts: 1921
Age: 30
That second image of the machine gun hacked looks like Quote slamming his hands downwards and sending a shock wave to the enemy.
 
Dec 2, 2007 at 2:26 PM
Hoxtilicious
"Life begins and ends with Nu."
Join Date: Dec 30, 2005
Location: Germany
Posts: 3218
Age: 32
Oh fu...

Thats fucking amazing!
You guys rock! :p
Thank you, now I've got enough to continue my FAQ. I'll get the missing "Assembly" offsets.

Xaser said:
It would be kinda neat to change the fireball into a grenade-launcher-ish weapon, though if I did that I would probably need a way to change the amount of fireballs allowed onscreen for each power level.

Well, I don't know if its possible, I guess so.
Actually I had the idea for a simular weapon, which is called "Explosive Louncher" actually it's a clone of the weapon in Gunner 3.
I could explain how it moves in a little drawing if you like.
 
Dec 4, 2007 at 10:34 AM
Luls
"Bleep, Bloop, Bleep, Bloop"
Join Date: Oct 6, 2007
Location: I dunnos
Posts: 1584
D:

YAYYY THANKS YOUZ!

*goes to hack*
 
Dec 11, 2007 at 6:22 PM
Junior Member
"Wow! The more I drink of this magical beverage, the more games I can play! Wheee!"
Join Date: Jul 15, 2007
Location:
Posts: 29
All hail cookie for sharing the offsets :o Figured out some more maximum number of shots offsets:
Code:
0x1dc15 - Snake (all levels)
---
0x1dea5 - Polar Star (all levels)
---
0x1e13c - Fireball lv1
0x1e159 - Fireball lv2
0x1e176 - Fireball lv3
---
0x1e3e2 - Machinegun (all levels)
---
0x1e90d - Missile Launcher lv2
0x1e937 - Missile Launcher lv3
---
0x1efdf - Bubbler lv1
0x1f28f - Bubbler lv2 and lv3 (Note: only affects maximum number of bubbles floating by your side on lv3)
---
0x1f755 - Nemesis (all levels)
 
Dec 11, 2007 at 11:26 PM
Senior Member
"Master using it, and you can have this!"
Join Date: Nov 28, 2007
Location:
Posts: 86
Code:
0x1e481 - Super Missile Launcher lv2
0x1e86b - Super Missile Launcher lv3
That should be all of them.
 
Dec 11, 2007 at 11:38 PM
Hoxtilicious
"Life begins and ends with Nu."
Join Date: Dec 30, 2005
Location: Germany
Posts: 3218
Age: 32
Still Super Missile Launcher level 1 and Blade missing ;P
 
Dec 12, 2007 at 5:21 AM
Luls
"Bleep, Bloop, Bleep, Bloop"
Join Date: Oct 6, 2007
Location: I dunnos
Posts: 1584
Nuuuuuu I missed out on so much. Thanks so much for the update. I'm gonna start a mod soon enough. *Hope it holds out long enough for at least a demo release... HOLIDAYS ARE ENDING! T.T*

Btw, is there an offset that allows you to set wether or not the weapon is automatic? Like machine gun.

I'm not too good at hacking myself so I can only ehh kind of remind people of the stuff to be found out. Of course I am also trying to figure out stuff myself too :o

Edit - btw when I go to the offset for the number of maximum shots allowed on screen for the Machine gun, why is it 04? 4 is not the maximum number of shots allowed on screen by the Machine GUn... O.o

Edity - IT IS! I UNDERSTAND ALREADY.

Editiness - Btw SP, you forgot to include the number of ticks between bullets of Machine Gun into your FAQ. o.o
 
Top