Staredit Network > Forums > Modding Assistance > Topic: Iscript sprites -> max number of frames is 255?
Iscript sprites -> max number of frames is 255?
Jan 5 2017, 12:27 am
By: DirectShift  

Jan 5 2017, 12:27 am DirectShift Post #1



Hello, I want to make sure why the unit I just finished designing and adding to starcraft was failing, but I think I know why that is.

I read somewhere that the max number of images for an unit (for example zealot) is 255, is this true? because I'm using like 400.

Thanks



None.

Jan 5 2017, 1:52 am O)FaRTy1billion[MM] Post #2

👻 👾 👽 💪

The limit on frames should be 65535. The width and height are limited to 255, but frame count should not be an issue (for example, unit\zerg\zlurker.grp has 595 frames).

If you would like, you could post or PM the GRP and maybe the iscript you are using and I or someone could take a look at it to see what could be the issue.



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!

Jan 5 2017, 2:32 am DirectShift Post #3



Quote from O)FaRTy1billion[MM]
The limit on frames should be 65535. The width and height are limited to 255, but frame count should not be an issue (for example, unit\zerg\zlurker.grp has 595 frames).

If you would like, you could post or PM the GRP and maybe the iscript you are using and I or someone could take a look at it to see what could be the issue.

Thanks farty, I picked the grp and found that, for some reason, the grp converter just grabbed just 223 frames.

So, that was the issue!



None.

Jan 5 2017, 3:06 am DirectShift Post #4



Sorry, it keeps failing.
The problem appears in ZealotWalking, this is the code:

Quote
# ----------------------------------------------------------------------------- #
# This is a decompile of the iscript.bin file 'data\scripts\iscript.bin'
# created on: Mon Jan 02 21:35:02 2017
# ----------------------------------------------------------------------------- #

# ----------------------------------------------------------------------------- #
# This header is used by images.dat entries:
# 151 Zealot (protoss\zealot.grp)
.headerstart
IsId 163
Type 21
Init ZealotInit
Death ZealotDeath
GndAttkInit ZealotGndAttkInit
AirAttkInit [NONE]
Unused1 [NONE]
GndAttkRpt ZealotGndAttkRpt
AirAttkRpt [NONE]
CastSpell [NONE]
GndAttkToIdle ZealotGndAttkToIdle
AirAttkToIdle [NONE]
Unused2 [NONE]
Walking ZealotWalking
WalkingToIdle ZealotWalkingToIdle
SpecialState1 [NONE]
SpecialState2 [NONE]
AlmostBuilt [NONE]
Built [NONE]
Landing [NONE]
LiftOff [NONE]
IsWorking [NONE]
WorkingToIdle [NONE]
WarpIn ZealotWarpIn
.headerend
# ----------------------------------------------------------------------------- #

ZealotInit:
imgul 152 0 0 # ZealotShad (protoss\pzeShad.grp)
ZealotWalkingToIdle:
playfram 0xaa # frame set 5
goto ZealotLocal00

ZealotLocal00:
wait 125
goto ZealotLocal00

ZealotDeath:
playsnd 678 # Protoss\ZEALOT\PZeDth00.WAV
setfldirect 0
playfram 0x198 # frame set 13
wait 2
playfram 0x199 # frame set 13
wait 2
playfram 0x19a # frame set 13
wait 2
playfram 0x19b # frame set 13
wait 2
playfram 0x19c # frame set 13
wait 2
playfram 0x19d # frame set 13
wait 2
playfram 0x19e # frame set 13
wait 2
playfram 0x19f # frame set 13
wait 2
end

ZealotGndAttkInit:
playfram 0x00 # frame set 0
wait 1
ZealotGndAttkRpt:
playsndrand 2 662 663 # Protoss\ZEALOT\pzeAtt00.WAV, Protoss\ZEALOT\pzeAtt01.WAV
playfram 0x11 # frame set 1
wait 1
nobrkcodestart
playfram 0x22 # frame set 2
wait 1
playfram 0x33 # frame set 3
wait 1
playfram 0x44 # frame set 4
wait 1
playfram 0x55 # frame set 3
wait 1
playfram 0x66 # frame set 2
wait 1
playfram 0x77 # frame set 1
attackmelee 1 664 # Protoss\ZEALOT\pzeHit00.WAV
wait 1
playfram 0x88 # frame set 1
wait 1
playfram 0x99 # frame set 0
nobrkcodeend
gotorepeatattk
ignorerest
ZealotGndAttkToIdle:
goto ZealotWalkingToIdle

ZealotWalking:
move 4
wait 1
playfram 0xbb # frame set 5
move 4
wait 1
playfram 0xcc # frame set 6
move 4
wait 1
playfram 0xdd # frame set 7
move 4
wait 1
playfram 0xee # frame set 8
move 4
wait 1
playfram 0xff # frame set 9
move 4
wait 1
playfram 0x110 # frame set 10
move 4
wait 1
playfram 0x121 # frame set 11
move 4
wait 1
playfram 0x132 # frame set 11
move 4
wait 1
playfram 0x143 # frame set 11
move 4
wait 1
playfram 0x154 # frame set 11
move 4
wait 1
playfram 0x165 # frame set 11
move 4
wait 1
playfram 0x176 # frame set 11
move 4
wait 1
playfram 0x187 # frame set 12
goto ZealotWalking

ZealotWarpIn:
imgol 154 0 0 # Unknown154 (protoss\zealot.grp)
goto ZealotLocal00



im also adding the grp

Attachments:
zealot.grp
Hits: 2 Size: 440.98kb



None.

Jan 5 2017, 6:44 pm O)FaRTy1billion[MM] Post #5

👻 👾 👽 💪

Have you updated pzeShad.grp? Since it now has far fewer frames than zealot.grp, it could be what is crashing. Try removing or commenting out the imgul under ZealotInit and see if that makes it no longer crash.



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!

Jan 5 2017, 6:51 pm Pr0nogo Post #6



In images.dat, change the entry for the zealot shadow to reference the zealot grp. It'll create an accurate shadow of your grp.




Jan 5 2017, 7:17 pm O)FaRTy1billion[MM] Post #7

👻 👾 👽 💪

Yes, that too. And I'm not sure how familiar you are with iscript, but be sure to change the imgul to have a y offset so you can see the shadow in that case. Something like imgul 152 0 7 (based on probe's and vulture's shadow).



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!

Jan 5 2017, 9:37 pm DirectShift Post #8



Quote from Pr0nogo
In images.dat, change the entry for the zealot shadow to reference the zealot grp. It'll create an accurate shadow of your grp.

Great effect, I thought I had to also draw all the shadows!!

Quote from O)FaRTy1billion[MM]
Yes, that too. And I'm not sure how familiar you are with iscript, but be sure to change the imgul to have a y offset so you can see the shadow in that case. Something like imgul 152 0 7 (based on probe's and vulture's shadow).

I know programming languages, so I understand iscript.
Thanks for the clarification, it was definitely a problem with shadows!!!



None.

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[2026-6-23. : 3:29 am]
DarkenedFantasies -- Probably just didn't care. For example, at some point before release, they've updated the graphics of some of the Protoss buildings (Forge, CyberCore, Citadel, Observatory, Arbiter Tribunal), but instead of properly re-rendering them with edited 3D models, they did crappy copy-paste jobs on the rendered graphics.
[2026-6-22. : 8:35 pm]
Ultraviolet -- :wob:
[2026-6-21. : 11:38 pm]
Symmetry -- :wob:
[2026-6-21. : 4:56 am]
Ultraviolet -- I suppose we'll likely never know, but my guess would be that they already saw it operating successfully and there was no monetary incentive to finish the original work. And the dev cycle in old school Blizzard was so hectic, it's possible it just got forgotten about after the original game got released. Plus there's an element of existing MPQ files that were packaged with the original discs becoming outdated if they updated it. And it's not like they remade the original MPQs, they just made new ones for BW specifically
[2026-6-21. : 4:26 am]
Oh_Man -- so that makes me think maybe the theory they are unfinished is not true and its a deliberate design decision, coz why not finish them wen ur making brood war?
[2026-6-21. : 4:25 am]
Oh_Man -- the thing is thos buildings are from classic. that means they went ahead and made brood war without ever finishing the 'unfinished' buildings
[2026-6-20. : 6:15 pm]
Ultraviolet -- Yeah he's talked about a lot of that stuff in his casts before. It seems plausible. Especially knowing how Blizzard of yesteryear operated.
[2026-6-20. : 3:47 pm]
NudeRaider -- to clarify: couldn't recall the behavior for every single Protoss building but I was aware the disparity exists.
[2026-6-20. : 3:43 pm]
NudeRaider -- Contained nothing new for me. Didn't know all building's behavior, but very much all unit's. Also Terran balance whine - also nothing new :lol:
[2026-6-19. : 9:57 am]
Oh_Man -- makes me wonder if SEN knows anything about the topic
Please log in to shout.


Members Online: Roy