FireGraft 1.16.1 (primarily exe edit discussion)

Help - Resources - AI Scripting - Grafting - Plugins - Modding Projects
matefkr
Posts: 86
Joined: Tue Jun 05, 2007 9:38 pm

Postby matefkr » Mon Feb 27, 2012 5:40 pm

What do u mean by that?

I made a few exe modifications so that allies can cooperate more (without extending the executable file, so i guess they can be firegraft exe mods that way). i gonna convert them later. files in attach.

EDIT: apparently there is a problem with upgrading buildings. upgrade stops inevitably. There was shield battery problem when recharged but its fixed. i cant upload files btw.
pastelmind
Posts: 57
Joined: Fri Nov 19, 2010 7:50 am

Postby pastelmind » Sun Apr 08, 2012 10:33 am

@DiscipleOfAdun: Would the attached file suffice? Personally, I think EXE edit links (Prev/Next) would be better off grouped together in the XML, and something really needs to be done about the whole jump tables thing.
pastelmind
Posts: 57
Joined: Fri Nov 19, 2010 7:50 am

Postby pastelmind » Wed Apr 11, 2012 5:45 pm

Edit: File became outdated and subsequently removed.

Hello folks. I just broke my promise not to work on FireGraft anymore. :P

Bug Fixes:
* Defensive Matrix damage amount: Should work properly now(shows 64000, which is 250 damage * 256).
* Maximum larva count: Sorry about that. Things like this happen when you convert offsets via binary text comparisons.
* No unit is allowed to have more than 255 max energy. In one of the previous versions I changed existing edits to allow more than 255 max energy, only to find that SC rolls over 255 energy to 0. Whoops!
* Doubling weapon damage displayed for Firebats/Zealots: The doubling should properly affect bonus damage.

New EXE Edits:
* Allow buildings to recharge shields (minus the construction-halting bug!)
* Allow Lurkers to damage friendly units (unaffected by weapons.dat)
* Allow Lurkers to damage themselves.


Note: I split the damage display edits to a separate tree. So if you want to update your mod to accompany this version of FireGraft, you will probably have to rebuild the EXE from scratch, including all the button set edits/tech tree changes/spell requirements. Big ouch. You can reuse everything else (DAT/BIN/GRP/WAV/TBL/whatever files) though.
DiscipleOfAdun
Posts: 37
Joined: Sat May 05, 2007 9:39 pm

Postby DiscipleOfAdun » Wed Apr 11, 2012 7:33 pm

pastelmind wrote:@DiscipleOfAdun: Would the attached file suffice? Personally, I think EXE edit links (Prev/Next) would be better off grouped together in the XML, and something really needs to be done about the whole jump tables thing.
The exe edits actually will have a whole new system which addresses those concerns and is far more flexible. What i needed were the Upgrades, Techs, and Orders listed out that way.
RavenWolf
Posts: 45
Joined: Sat Jun 25, 2011 1:03 am

Postby RavenWolf » Fri Apr 13, 2012 9:26 pm

Its good that people still working on this!
may be someone can have the answers to thing that im trying to figure out:

Why is not possible to moddify carrier upgrade capassity?
pastelmind
Posts: 57
Joined: Fri Nov 19, 2010 7:50 am

Postby pastelmind » Sun Apr 15, 2012 2:51 pm

AFAIK it's probably because each Carrier has an hardcoded array with a length of 8, with each element pointing to one of its Interceptors. It's much more work than just changing a number or two in the code.

Also, I finally managed (thx to IDA pro and Heinermann) to make that one EXE edit that eluded me for over a year.

  • Make plague deal damage like a weapon
What this does is, it makes Plague very similar to Fungal Growth in SC2: deal a fixed amount of damage over time, possibly killing the victim.

Mind you, it also obeys the Weapon Type setting for Plague (ID: 60) in weapons.dat, which is set to 'Independent' by default, which makes it deal 0.5 point of damage per hit! So change it to 'Normal' or 'Ignore Armor'.

Modding tip

The actual damage of plague is (weapons.dat damage) / 76. So if you set Plague's damage to 152 in weapons.dat, it will deal exactly 2 damage per every 8 frames.

Edit: Attached file was outdated and therefore removed.
DiscipleOfAdun
Posts: 37
Joined: Sat May 05, 2007 9:39 pm

Postby DiscipleOfAdun » Sun Apr 15, 2012 7:16 pm

RavenWolf wrote:Its good that people still working on this!
may be someone can have the answers to thing that im trying to figure out:
Why is not possible to moddify carrier upgrade capassity?


pastelmind wrote:AFAIK it's probably because each Carrier has an hardcoded array with a length of 8, with each element pointing to one of its Interceptors. It's much more work than just changing a number or two in the code.



If that were the case, why can you edit the starting amount then?

I believe I answered the question in the Hint for the edit when I initially released it. The assembly code was generated in a way that the amount cannot be changed without a rewrite of the function it resides in.

(None of the examples that follow are the exact issue with the carrier upgrade, but the principles are similar)

Assembly is designed to be as compact and fast as possible, and sometimes that means making certain assumptions about the code. One of the most easy and fixed assumptions is that any variable that is only given a single value always will stay that value, and the constant value can be used in place of that variable. Second, certain numbers allow for tricks to be used in assembly. Multiplying a small number by 2 is a common one, where it just becomes shifting each bit in the binary number left by 1 place. With something like that, there is no super easy way to change it to multiply by 3 unless you rewrite the instruction. The code that changes the capacity based off the upgrade is similar, where it is not easily changeable.
RavenWolf
Posts: 45
Joined: Sat Jun 25, 2011 1:03 am

Postby RavenWolf » Mon Apr 16, 2012 8:54 pm

DiscipleOfAdun wrote:I believe I answered the question in the Hint for the edit when I initially released it. The assembly code was generated in a way that the amount cannot be changed without a rewrite of the function it resides in.
yep, but seen that the reaver can be modified i thoug that it would be similar. Thanks for the explanation, i didnt know much of assembly. But anyway, i think i can solve my problems with plugin.

Also, I finally managed (thx to IDA pro and Heinermann) to make that one EXE edit that eluded me for over a year. Make plague deal damage like a weapon
That's great! i will have to test it, I'm sure i can make a good use of this :)
pastelmind
Posts: 57
Joined: Fri Nov 19, 2010 7:50 am

Postby pastelmind » Sun Apr 22, 2012 5:11 pm

Edit: This copy of FireGraft was outdated. It has been removed.

DiscipleOfAdun wrote:If that were the case, why can you edit the starting amount then?
(and so on)
Bah, now I feel dumb.

To make up for that dumbness, here are some new EXE edits.
  • Modify Carrier Capacity upgrade amount (also allows multiple upgrades to stack!)
  • Modify elevation level of Dark Swarm/Disruption Web
  • Also changed "Preserve unit properties upon spawning" to "Enable Collision"
  • Change by how much Dark Swarm shifts weapon sprites (try it and you'll understand)

As usual, this FireGraft is incompatible with previous ones, you'll have to rebuild it from scratch. Sorry again. :(

I'm open to EXE edit suggestions, as I'm no longer working on any modding projects now.
pastelmind
Posts: 57
Joined: Fri Nov 19, 2010 7:50 am

Postby pastelmind » Tue May 08, 2012 7:12 pm

Edit: Removed file because it was outdated.

RavenWolf wrote:lurker/muta morph supply check stuff
I looked into the assembly code; the Lurker is hardcoded to substract Hydralisk supply when morphing. I usually use empty space between functions to rewrite assembly code, but this one doesn't seem to have much space nearby. It's a pity the same code is used for larvae morphing into everything else.

RavenWolf wrote:The second one its an option to display the actual supply count (required, provided, and used) instead of having it halved.
If I knew which function printed the numbers and the icons to the top right of the screen...

RavenWolf wrote:-Possibility to change/nullify the random modifier on weapons cooldowns.
-Possibility to change/nullify the chance of miss an attack for units on a lower cliff level.
Changing the randomness might be hard. Totally removing it would be easier. (mental note: see doWeaponIscript())

Miss chance can be done. (mental note: see isUnderDarkSwarm())


Also, new EXE Edits:
  • Modify how the AI responds to cloaked/burrowed enemies (which detector to bring, which building to use for Scanning, etc.)
  • Change the spell that Queens use against invisible foes. (by default, it casts Ensnare)

Essentially, you can make a Scout into a detector, and then make the AI bring it toward any cloaked enemies.

Return to “StarCraft Modding”

Who is online

Users browsing this forum: No registered users and 2 guests