Staredit Network > Forums > SC1 UMS Mapmaking Assistance > Topic: how to break 65k hp limit and another thng
how to break 65k hp limit and another thng
May 23 2017, 5:55 pm
By: Terran_Legionnaire  

May 23 2017, 5:55 pm Terran_Legionnaire Post #1



i'll keep this brief while being specific as possible.

i've ran into a dead end and tried evrythng within my knowledge both my own/google's. i'm using scmdraft 2 v-0.8.0 and using cheat engine v-6.6 to modify the hp amount higher than the cap but, after doing the 1st scan, i click bak to sc only to crash and this repeats.

google is limited on search resultz in regards to this so i've hit a wall with no way arnd it

the other thng; which i'm aware is unfavorable among the community of sorts, is map unprotection

bear in mind, i haven't unprotected a map in 5yrs or so and i've only done so in the past to reverse engineer maps to fix bugs and remained anon and i'm vry careful in regardz to this, disabling original triggers and replacing it with my new 1 instead of deleting it altogether.

so here's the issue; if any1 is allowed to assist in this matter, i've used scunprotect and UU2 v-final and both seem to unprotect but 100% fails to save evry time. again, google searches r vry limited on this as well.

reason why i want to unprotect maps is for reference on how i would create a particular trigger without bombarding forumz evry 5mins

anyways, that's all i got, thousand thx in advance for ur time and assist.

specz: i run a win 7 x64



None.

May 23 2017, 6:31 pm rockz Post #2

ᴄʜᴇᴇsᴇ ɪᴛ!

HP is stored in 4 bytes. The first byte is extra precision which allows for 0.5 damage, and regeneration (zerg regenerate at 4/frame). You can set maximum HP to exactly 4 bytes, which is 4,294,967,295. You're unable to actually set this in SCMDraft since it tries to help you by splitting HP into 3 bytes and 1 byte. Normally the 1 byte is set to 0 so that you have a nice whole number for maximum HP.

That means your maximum HP is actually 16777215 + 255. The display also shows this number as signed, so 16777215 will show as -1 HP, and will likely show up as -1 in SCMDraft as well, but Starcraft will treat that number as unsigned. If you want to avoid all that, then the maximum is 8388608 + 255. This number might be hidden from you in SC. I haven't played in the new patch yet, so numbers higher than 2 bytes (65535) may crash the game. It might also be likely that outside changes will crash starcraft, so you might have to edit the CHK directly to get these high values.

You'll want to use the latest version of SCMDraft, which is uploaded here: http://www.staredit.net/topic/8307/

You can use Trigger Viewer to view triggers without unprotecting the map. Unprotecting maps is a finicky process. We can't support unprotecting maps in any way unfortunately, despite my personal feelings on map protection.



"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"

May 23 2017, 6:49 pm Suicidal Insanity Post #3

I see you !

Scmdraft sets the value as [3byte number] << 8 | [1byte number], so you should have access to the full range of values. I always thought the lobyte was used to do funky things with wireframes or invulnerability




May 23 2017, 9:36 pm Terran_Legionnaire Post #4



@rockz thx man, got the latest scm and i'll try out the trig viewer when i get a chance. i'm also gonna do some research on the chk editing bit, as anythng beyond wat scmdraft can actually do is new territory for me.

@suicidal instanity if i do, i certainly don't know how to get to it XD i'll see wat i can dig up on research

thx for the assist gys



None.

May 23 2017, 10:05 pm rockz Post #5

ᴄʜᴇᴇsᴇ ɪᴛ!

Max display HP doesn't actually use the last byte, just the first 3, so if you set it to anything other than zero, you'll end up with a fully healed unit at something like 61/60. It's not actually a full 1.

http://www.starcraftai.com/wiki/CHK_Format

here's a link to the CHK format description, which is what you can use to edit a lot of stuff in the actual map file, as well as recover maps, since you can actually split up the entire map into each chunk and reassemble it if you need to.



"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"

May 23 2017, 10:12 pm Suicidal Insanity Post #6

I see you !

Ya its like a really hackish 24.8 fixed point




May 23 2017, 10:42 pm Terran_Legionnaire Post #7



Quote from rockz
Max display HP doesn't actually use the last byte, just the first 3, so if you set it to anything other than zero, you'll end up with a fully healed unit at something like 61/60. It's not actually a full 1.

http://www.starcraftai.com/wiki/CHK_Format

here's a link to the CHK format description, which is what you can use to edit a lot of stuff in the actual map file, as well as recover maps, since you can actually split up the entire map into each chunk and reassemble it if you need to.

i actually have that in a separate tab XD

as i said earlier; i'm diving into unknown territory here and can't seem to get scmdraft to access the chk file associated with the map. i'm also being pointed toward an mpq editor tool in my research, so i'm approaching this with a bit of care.



None.

May 23 2017, 10:50 pm rockz Post #8

ᴄʜᴇᴇsᴇ ɪᴛ!

I think CHKdraft will edit the CHK, but essentially you'd have to hex edit the scenario.chk after you unpack the mpq archive. Since you're familiar with cheatengine, it shouldn't be too difficult, but I recommend you focus on getting SCMDraft to work properly.



"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"

May 23 2017, 11:06 pm Terran_Legionnaire Post #9



Quote from rockz
I think CHKdraft will edit the CHK, but essentially you'd have to hex edit the scenario.chk after you unpack the mpq archive. Since you're familiar with cheatengine, it shouldn't be too difficult, but I recommend you focus on getting SCMDraft to work properly.

i appreciate the amount of faith u have in me but, in terms of cheat engine, i'm only familiar with "find the OG value, scan, change OG value, scan new value" rinse repeat till list is narrowed down to the address associated with its usage and change freely.

as far as that goes, i'm gonna need further instruction on wat needs to b prep'd in scmdraft b4 moving on, i'll grab chkdraft real quick, as mpq editor extracted "scenario.chk" alrdy and it opens much the same way as i would double clicking the map file itslf.

thx again for the assist man, for real.

editz: went thru roy's EUD 101 and now have a basic understanding of it, i got SCMDraft 2 v-0.8.1, cheat engine 6.6, and Farty's EUDTrig v-1.3.

the only thng standing between me and wat i want to accomplish is sc crashing while scanning for addresses in regards to unit hp. i ran both sc and cheat engine as admin and same thng happens. if any1 has a particular fix for this lmk and i'll get to wrk and will update on wat happened.

thx in advance

Post has been edited 1 time(s), last time on May 24 2017, 5:18 am by Terran_Legionnaire.



None.

May 24 2017, 4:17 pm Terran_Legionnaire Post #10



for any modz in this subforum, u can mark this thread as closed now, sorta almost have it figured out and i'm pretty sure i can get wat i need if i do some trial/error.

thx all for the assist on this :D



None.

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[09:24 pm]
Moose -- denis
[05:00 pm]
lil-Inferno -- benis
[10:41 am]
v9bettel -- Nice
[01:39 am]
Ultraviolet -- no u elky skeleton guy, I'll use em better
[10:50 pm]
Vrael -- Ultraviolet
Ultraviolet shouted: How about you all send me your minerals instead of washing them into the gambling void? I'm saving up for a new name color and/or glow
hey cut it out I'm getting all the minerals
[2024-4-18. : 10:11 pm]
Ultraviolet -- :P
[2024-4-18. : 10:11 pm]
Ultraviolet -- How about you all send me your minerals instead of washing them into the gambling void? I'm saving up for a new name color and/or glow
[2024-4-17. : 11:50 pm]
O)FaRTy1billion[MM] -- nice, now i have more than enough
[2024-4-17. : 11:49 pm]
O)FaRTy1billion[MM] -- if i don't gamble them away first
[2024-4-17. : 11:49 pm]
O)FaRTy1billion[MM] -- o, due to a donation i now have enough minerals to send you minerals
Please log in to shout.


Members Online: jjf28