Staredit Network > Forums > Modding Assistance > Topic: Unit Data
Unit Data
May 28 2008, 2:52 am
By: rockz  

May 28 2008, 2:52 am rockz Post #1

ᴄʜᴇᴇsᴇ ɪᴛ!

Each unit has 336 bytes associated with them. Do we have a map somewhere of this? I know most of them don't actually do anything, but I'd still like to know what's known (like the byte for blind or parasited).



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

May 28 2008, 3:09 am O)FaRTy1billion[MM] Post #2

👻 👾 👽 💪

It's in the reference tab of the EUDDB.



TinyMap2 - Latest in map compression! ( 7/09/14 - New build! )
EUD Action Enabler - Lightweight EUD/EPD support! (ChaosLauncher/MPQDraft support!)
EUDDB - topic - Help out by adding your EUDs! Or Submit reference files in the References tab!
MapSketch - New image->map generator!
EUDTrig - topic - Quickly and easily convert offsets to EUDs! (extended players supported)
SC2 Map Texture Mask Importer/Exporter - Edit texture placement in an image editor!
\:farty\: This page has been viewed [img]http://farty1billion.dyndns.org/Clicky.php?img.gif[/img] times!

May 28 2008, 3:11 am poiuy_qwert Post #3

PyMS and ProTRG developer

This comes from DOAs notes:

Code
CUNIT STRUCT
+0x0 - CUNIT* Previous
+0x4 - CUNIT* Next
+0x8 - DWORD dwHP
+0xC - CSPRITE* Sprite
+0x10 - WORD wMoveToXPos
+0x12 - WORD wMoveToYPos
+0x14 - CUNIT* Target_1
+0x18 - WORD wCurrentXPos_?
+0x1A - WORD wCurrentYPos_?
+0x1C - WORD wX_?
+0x1E - WORD wY_?
+0x20 - BYTE bMovementFlags_?
2 - Making Building?
4 - Moving?

+0x22 - BYTE bFlingyTurnRadius
+0x23 - BYTE bCurrentDirection_?
+0x24 - WORD wFlingyID

+0x27 - BYTE bFlingyMovementType
+0x28 - WORD wCurrentXPos
+0x2A - WORD wCurrentYPos
+0x2C - DWORD dwX_Halt
+0x30 - DWORD dwY_Halt
+0x34 - DWORD dwFlingySpeed
+0x38 - DWORD dwUnknown_38_Speed
+0x3C - DWORD dwUnknown_3C_Speed

+0x48 - WORD wFlingyAcceleration

+0x4C - BYTE bPlayerID
+0x4D - BYTE bMainOrderID
+0x4E - BYTE bMainOrderState
+0x4F - BYTE bOrderSignal

+0x54 - BYTE bMainOrderTimer
+0x55 - BYTE bGroundWeaponCooldown
+0x56 - BYTE bAirWeaponCooldown
+0x57 - BYTE bSpellCooldown
+0x58 - WORD wOrderTargetX
+0x5A - WORD wOrderTargetY
+0x5C - CUNIT* Target_Order
+0x60 - DWORD dwShield
+0x64 - WORD wUnitID
+0x68 - CUNIT* PlayerPrevious
+0x6C - CUNIT* PlayerNext
+0x70 - CUNIT* Subunit
+0x74 - CORDER* OrderQueueHead
+0x78 - CORDER* OrderQueueTail

+0x7C - Unknown AI Cloak

+0x80 - CUNIT* ConnectedUnit

+0x84 - BYTE bNumOfQueuedOrders
+0x85 - BYTE bUnknown_85_Order_Timer_Seperate

+0x88 - WORD wDisplayedUnitID?

+0x8E - BYTE bRankIncrease
+0x8F - BYTE bKillCount

+0x93 - BYTE bUnknownState?
+0x94 - BYTE bCurrentButtonSet
+0x98 - WORD wQueue1
+0x9A - WORD wQueue2
+0x9C - WORD wQueue3
+0x9E - WORD wQueue4
+0xA0 - WORD wQueue5
+0xA2 - WORD wEnergy
+0xA4 - BYTE bQueueSlot

+0xA6 - BYTE bSecondaryOrderID
-Cloak, Build, expand creep
+0xA8 - WORD bHPGainDuringBuild/Repair?

+0xAC - WORD wRemainingBuildTime

UNION
WORD
+0xC0 - BYTE bSpidermineCount
+0xC1 - BYTE bUnusedC1
+0xC2 - BYTE bUnusedC2
+0xC3 - BYTE bUnusedC3
CUNIT
+0xC0 - CUNIT* Unit_Unknown_1
IF Carrier/Reaver - First Hangar Unit
IF Scarab/Interceptor - Parent
IF Building - Addon
IF Worker - Powerup Carried
UNION
WORD
+0xC4 - WORD wAddonBuildID
+0xC6 - WORD wUpgradeResearchTime
CUNIT*
+0xC4 - CUNIT* Unit_Unknown_2
IF Scarab/Interceptor - Next Unit in Parent Hangar
UNION
BYTE
+0xC8 - BYTE bScarabCount/bTechID
+0xC9 - BYTE bInterceptorCount/bUpgradeID
+0xCA - BYTE bLarvaSpawnTimer
+0xCB - BYTE bIsLanding
CUNIT
+0xC8 - CUNIT* Unit_Unknown_2
IF Scarab/Interceptor - Previous in Parent's Hangar
+0xCC - BYTE b_Unknown
-IF Interceptor/Scarab - InHanger?
-IF CreepUnit - timer between creep expansions
-IF Repairing - decrease mineral timer
+0xCD - BYTE bUpgradeLevel
+0xCE - BYTE bIsCarryingSomething?/Going to carry something?/Targeting Resources?
+0xCF - BYTE bResourceAmount
UNION
WORD/BYTE
+0xD0 - WORD wResourceContained/wPowerupDropTargetX
+0xD2 - WORD wPowerupDropTargetY
+0xD2 - BYTE bResourceIscript
+0xD3 - BYTE bResourceCount?
DWORD
+0xD0 - CUNIT ResourceTarget/NydusConnected
+0xD0 - CSPRITE NukeDot


+0xDC - DWORD dwStatus
00000001(0x1) - Is Completed
00000010(0x2) - Is on ground? or is it is unit...
00000100(0x4) - Is in air
00001000(0x8) - Checked for disabled, if it is 00001000, then the unit is disabled(/unpowered?)
00010000(0x10) - Checked for burrowing purposes, if it is 00010000, then the unit is burrowed
00100000(0x20) - Unit is entering a building
01000000(0x40) - unit is entering a transport
10000000(0x80) -

00000001(0x100) - Checked for invisible purposes, if it is 00000001, then the unit requires a detector?
00000010(0x200) - checked for cloak?
00000100(0x400) - deals with doodad states? if set, is disabled
00001000(0x800) - Unit cloaking doesn't need energy decrease
00010000(0x1000) - Unit is in unbreakable code section? Cannot receive orders
00100000(0x2000) - Set by nobrkcodestart
01000000(0x4000) -
10000000(0x8000) - cannot attack if set

00000001(0x10000)
00000010(0x20000) - Is a Building?
00000100(0x40000)
00001000(0x80000) - Unit is Unmovable

00000100(0x4000000) - Invincible

00010000(0x10000000) - Speed upgrade
00100000(0x20000000) - cooldown upgrade
01000000(0x40000000) -

+0xE0 - BYTE bResouceType
+0xE1 - BYTE bWireframeRandomizer
+0xE2 - BYTE bSecondaryOrderState
+0xE3 - BYTE bUnknown_E3_Counter_Down

+0xEC - CUNIT* CurrentBuildUnit

UNION
WORD/CUNIT
+0xF8 - WORD wRallyX
+0xFA - WORD wRallyY
+0xFC - CUNIT* RallyUnit
CUNIT
+0xF8 - CUNIT* PreviousPsiProvider
+0xFC - CUNIT* NextPsiProvider
+0x100 - DWORD dwPath_Unknown

+0x106 - BYTE bUnused_106
+0x107 - BYTE bIsBeingHealed
+0x108 - WORD wX_Contours_1_Unknown
+0x10A - WORD wY_Contours_1_Unknown
+0x10C - WORD wX_Contours_2_Unknown
+0x10E - WORD wY_Contours_2_Unknown
+0x110 - WORD wRemoveTimer
Hallucination, DSwarm, DWeb, Broodling
+0x112 - WORD wDMatrixDamage
+0x114 - BYTE bDMatrixTimer
+0x115 - BYTE bStimTimer
+0x116 - BYTE bEnsnareTimer
+0x117 - BTYE bLockdownTimer
+0x118 - BYTE bIrradiateTimer
+0x119 - BYTE bStatisTimer
+0x11A - BYTE bPlagueTimer
+0x11B - BYTE bIsUnderStorm
Used to tell if a unit is under psi storm
+0x11C - CUNIT* IrradiatedBy
+0x120 - BYTE bIrradiatePlayerID
+0x121 - BYTE bParasiteFlags
Each bit corrisponds to the player who has parasited this unit
+0x122 - BYTE bCycleCounter
Runs updates 2 times per sec(about)
+0x123 - BYTE bIsBlind
+0x124 - BYTE bMaelstromCounter
+0x125 - bUnknown_Unreferenced
+0x126 - BYTE bAcidSporeCount
+0x127 - BYTE bAcidSpore1Time
+0x128 - BYTE bAcidSpore2Time
+0x129 - BYTE bAcidSpore3Time
+0x12A - BYTE bAcidSpore4Time
+0x12B - BYTE bAcidSpore5Time
+0x12C - BYTE bAcidSpore6Time
+0x12D - BYTE bAcidSpore7Time
+0x12E - BYTE bAcidSpore8Time
+0x12F - BYTE bAcidSpore9Time
+0x130 - WORD w3by3OffsetIndex
+0x132 - WORD wUnused_1325a
+0x134 - DWORD dwUnknown_134_CUNIT_AI
+0x138 - WORD wAirStrength(see equation below, 1 if has no air weapon but has a ground)
+0x13A - WORD wGroundStrength(see equation below, 1 if has no ground weapon but has an air)
+0x13C - DWORD dwTableID_Unknown_1
+0x140 - DWORD dwTableID_Unknown_2
+0x144 - DWORD dwTableID_Unknown_3
+0x148 - DWORD dwTableID_Unknown_4
+0x14C - BYTE bRepulse_Unknown_1
+0x14D - BYTE bRepulse_Unknown_2
+0x14E - BYTE bDriftPosX(mapsizex/1.5 max)
+0x14F - BYTE bDriftPosY(mapsizey/1.5 max)





May 28 2008, 3:17 am O)FaRTy1billion[MM] Post #4

👻 👾 👽 💪

Ya. All that is in the EUDDB.



TinyMap2 - Latest in map compression! ( 7/09/14 - New build! )
EUD Action Enabler - Lightweight EUD/EPD support! (ChaosLauncher/MPQDraft support!)
EUDDB - topic - Help out by adding your EUDs! Or Submit reference files in the References tab!
MapSketch - New image->map generator!
EUDTrig - topic - Quickly and easily convert offsets to EUDs! (extended players supported)
SC2 Map Texture Mask Importer/Exporter - Edit texture placement in an image editor!
\:farty\: This page has been viewed [img]http://farty1billion.dyndns.org/Clicky.php?img.gif[/img] times!

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[02:30 am]
Symmetry -- I dreamed about that as a kid. The idea of a computer capable of analyzing a starcraft map and calculating the fastest possible way to hit the victory condition
[02:29 am]
Symmetry -- But can AI beat my custom maps?
[12:32 pm]
Oh_Man -- yea APM vs eAPM
[08:48 am]
NimoStar -- plus most of the human APM is just spam clicking APM inflation
[08:47 am]
NimoStar -- the thing with the "*12" thing is completely misleading. The AI isn't using two control groups, it can use each of those actions to command a single unit individually and issue different commands to each single unit.
[08:06 am]
NudeRaider -- NudeRaider
NudeRaider shouted: Oh_Man Artosis hasn't caught on how devastating the perfect focus fire is. With the mutas he was like "the Mutas always seem to have less hp than against a human". But he didn't notice that the flock he had selected always just had one muta that was hurt. Same with the wraiths here. He's talking about how valks+wraith is gonna destroy Pluto's valks, then 5s later he's dumbfounded the human player's air is just gone and he never figured out why. And for some reason didn't even think to go back and look at the battle.
*Pluto's wraiths
[08:05 am]
NudeRaider -- Oh_Man Artosis hasn't caught on how devastating the perfect focus fire is. With the mutas he was like "the Mutas always seem to have less hp than against a human". But he didn't notice that the flock he had selected always just had one muta that was hurt. Same with the wraiths here. He's talking about how valks+wraith is gonna destroy Pluto's valks, then 5s later he's dumbfounded the human player's air is just gone and he never figured out why. And for some reason didn't even think to go back and look at the battle.
[2026-9-22. : 2:18 am]
Oh_Man -- Close enuf
[2026-9-21. : 4:14 pm]
Vrael -- perhaps there is a small professional player trapped in a box in the server rack where pluto is running? hmm?
[2026-9-21. : 4:14 pm]
Vrael -- 240*12*2 is 5760, where is the other 240 APM?
Please log in to shout.


Members Online: Zycorax, O)FaRTy1billion[MM], Symmetry