Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

missing signedDamage hack #40

Open
KangaRoo1372 opened this issue Aug 15, 2024 · 2 comments
Open

missing signedDamage hack #40

KangaRoo1372 opened this issue Aug 15, 2024 · 2 comments

Comments

@KangaRoo1372
Copy link

Hey again guys, sorry for spamming with new issues without providing ready-to-merge solutions for them, but I'm not very good at programming or coding and I'm afraid that if I tried, I'd break something. :P
Anyway, I have one more suggestion for an improvement. I mean, I see that the most popular "liero hacks" have been included in the worm.cpp and common_exereader.cpp files, i.e. signed recoil, air jump, fall damage, etc. However, the "signed damage" hack, which also appeared frequently in many TCs, is missing from this list. The lack of it means that the given weapon with such hack will work not work as intended if you open a TC with such weapon with openliero.exe (or convert it with tc_tool) - whereas it will work correctly when you play the game in the "traditional" way (i.e. run it with dosbox).
Btw, I also suggest to add another hack, which (as far as I know) was not very popular back in the days, but it's also pretty cool, I mean "signed bounce" hack (activation of which causes bullets to pass through solid rock and dirt). The principle of activating this hack is the same as signed damage: you have to change a few bytes, according to the "two's complement" principle.

@grawlinson
Copy link
Collaborator

Yo! Got any documentation or example TCs that include these hacks?

@KangaRoo1372
Copy link
Author

KangaRoo1372 commented Nov 8, 2024

Hey! Yes, the documentation on how to implement the "signed damage" hack in classic Liero.exe can be found here. Basically, the hack involves changing bits in the .exe file at hex 6D10 (from 30E4 to 9890). It's similar to "signed recoil" hack (which is also based on two's complement rule but ofc with other bits to be changed).
The TCs which include this hack are sorliero (weapon HEALING and SANCTUARY) and LieroPT (weapon HEAL).
And what about the "signed bounce" hack - it seems that this topic is outdated, because I made some tests with your (open)liero 1.39 and it turns out that this effect can already be achieved in Liero 1.39 by setting the bounce value to -100 in the .cfg file for any weapon. So I guess no need to add this hack anymore in the code (however, maybe it could be possible to implement the "signed damage" thing in the same way as it was done with the bounce parameter?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants