Staredit Newtork
Community
StarCraft
Games
Site
Favourites
How NOT to iscript., In other words, help plz.

Pages: < 1 2 3
Creator: HailFire
Time: May 21 2008, 8:54 pm

Post #41     HailFire May 31 2008, 9:14 pm

[Avatar]
He's in ur base, killin' ur d00dz.
 offline contact
Quote from A_of-s_t
It supposed to go to a wait block:

Code

NexusIsWorking:
playfram 0
wait 3
playfram 2
wait 3
playfram 3
wait 3
playfram 4
wait 3
playfram 3
wait 3
playfram 2
wait 3
goto NexusLocal00


But, yeah, making protoss emulate terran buildings are a pain. Or hell, editting protoss buildings in general.

Where NexusLocal00 = ?
Top

Post #42     A_of-s_t May 31 2008, 9:19 pm

[Avatar]
Master of Temptation, Ruler of Aeronotics, and Secret Lover
 offline contact
Quote from HailFire
Where NexusLocal00 = ?

Its any wait block. It usually looks like this:

Code

ZOMGIMAWAITBLOCK:
wait    125
goto ZOMGIMAWAITBLOCK
From silent:
"lolol First of all wikipedia is flawed because anyone can come into it and post anything. About criticism.. no. You can't just change the definition of a word and expect everyone to bow down in awe. I am using macro evolution as an identifier between changing from one kind to another kind. I.E. bananas turning into flies. So if you want to argue about this then your argueing about the definition of a word.. Not the theory itself. If you want I can use false evolution, or neverbeenseenbefore evolution instead of macro. Its up to you"
This is stupidity. Please look at it very closely -- notice that almost every logical fallacy is used in it.
Top

Post #43     HailFire May 31 2008, 9:28 pm

[Avatar]
He's in ur base, killin' ur d00dz.
 offline contact
Quote from A_of-s_t
Quote from HailFire
Where NexusLocal00 = ?

Its any wait block. It usually looks like this:

Code

ZOMGIMAWAITBLOCK:
wait    125
goto ZOMGIMAWAITBLOCK

I already tried that (Wherein waitblock = NexusWalking)

Here's the current full Nexus iscript:

Code

#

------------------------------------------------------

----------------------- #
# This header is used by images.dat entries:
# 179 Nexus (protoss\nexus.grp)
.headerstart
IsId               177
Type               21
Init               NexusInit
Death               NexusDeath
GndAttkInit         [NONE]
AirAttkInit         [NONE]
Unused1             [NONE]
GndAttkRpt         [NONE]
AirAttkRpt         [NONE]
CastSpell           [NONE]
GndAttkToIdle       [NONE]
AirAttkToIdle       [NONE]
Unused2             [NONE]
Walking             NexusWalking
WalkingToIdle       [NONE]
SpecialState1       [NONE]
SpecialState2       [NONE]
AlmostBuilt         [NONE]
Built               NexusBuilt
Landing             [NONE]
LiftOff             [NONE]
IsWorking           NexusIsWorking
WorkingToIdle       NexusIsWorking
WarpIn             NexusWarpIn
.headerend
#

------------------------------------------------------

----------------------- #

NexusWalking:
    wait         125
    goto         NexusWalking

NexusInit:
    playfram           0
    goto               NexusWalking

NexusIsWorking:
    playfram     0
    wait         3
    playfram     2
    wait         3
    playfram     3
    wait         3
    playfram     4
    wait         3
    playfram     3
    wait         3
    playfram     2
    wait               3
    goto               NexusWalking

NexusDeath:
    playsnd             7     # Misc\ExploLrg.wav
    imgol               215 0 0     #

ProtossBuildingExplosionLarge (thingy\tBangX.grp)
    wait               3
    lowsprul           224 0 0     #

ProtossBuildingRubbleLarge (thingy\PRubbleL.grp)
    wait               1
    end                

NexusBuilt:
    goto               NexusWalking

NexusWarpIn:
    imgol               180 0 0     # NexusWarpFlash
    goto               NexusWalking


EDIT: With the above iscript, the Nexus only plays the working animation once, then stops. (it plays it again when the build order stops/cancels)
Top

Post #44     A_of-s_t May 31 2008, 9:34 pm

[Avatar]
Master of Temptation, Ruler of Aeronotics, and Secret Lover
 offline contact
Have a longer working animation or a random jump that happens about... 196/256?

EDIT: Nvm, you cant have random jumps or waits with buildings.
From silent:
"lolol First of all wikipedia is flawed because anyone can come into it and post anything. About criticism.. no. You can't just change the definition of a word and expect everyone to bow down in awe. I am using macro evolution as an identifier between changing from one kind to another kind. I.E. bananas turning into flies. So if you want to argue about this then your argueing about the definition of a word.. Not the theory itself. If you want I can use false evolution, or neverbeenseenbefore evolution instead of macro. Its up to you"
This is stupidity. Please look at it very closely -- notice that almost every logical fallacy is used in it.
Top

Post #45     HailFire May 31 2008, 9:50 pm

[Avatar]
He's in ur base, killin' ur d00dz.
 offline contact
It no werky.

I tried making the animation twice as long (via copypasta); it played the animation twice before stopping. :<_<:
Top

Post #46     FlyingHat May 31 2008, 9:54 pm

[Avatar]
 offline contact
I now see what you're going at. You need to make the nexus emulate the Command Center's work animation.
The command center doesn't use regular playframs to make it seem like it's working, it uses an overlay that uses this script. Added comments and stuff.

Code

# ----------------------------------------------------------------------------- #
# This header is used by images.dat entries:
# 276 CommandCenterOverlay (terran\controlT.grp)
.headerstart
IsId               103
Type               24
Init               CommandCenterOverlayInit
Death               CommandCenterOverlayDeath
GndAttkInit         [NONE]
AirAttkInit         [NONE]
Unused1             [NONE]
GndAttkRpt         [NONE]
AirAttkRpt         [NONE]
CastSpell           [NONE]
GndAttkToIdle       [NONE]
AirAttkToIdle       [NONE]
Unused2             [NONE]
Walking             CommandCenterOverlayDeath
WalkingToIdle       CommandCenterOverlayDeath
SpecialState1       CommandCenterOverlayDeath
SpecialState2       [NONE]
AlmostBuilt         [NONE]
Built               [NONE]
Landing             CommandCenterOverlayDeath
LiftOff             CommandCenterOverlayDeath
IsWorking           CommandCenterOverlayInit
WorkingToIdle       CommandCenterOverlayDeath
WarpIn             [NONE]
Unused3             [NONE]
StarEditInit       [NONE]
Disable             CommandCenterOverlayDeath
Burrow             [NONE]
.headerend
# ----------------------------------------------------------------------------- #

CommandCenterOverlayInit: #The overlay header
    playfram           0
    tmprmgraphicend    
    wait               4
    tmprmgraphicstart # hides the graphic until tmprmgraphicend is used
    wait               1
    tmprmgraphicend     #reveals the graphic until tmprmgraphicstart is used
    wait               1 #wait one tick
    tmprmgraphicstart    
    wait               1
    tmprmgraphicend    
    wait               3
    tmprmgraphicstart    
    wait               1
    tmprmgraphicend    
    wait               3
    tmprmgraphicstart    
    wait               1
    tmprmgraphicend    
    wait               4
    tmprmgraphicstart    
    wait               1
    tmprmgraphicend    
    wait               1
    tmprmgraphicstart    
    wait               1
    tmprmgraphicend    
    wait               3
    tmprmgraphicstart    
    wait               1
    tmprmgraphicend    
    wait               3
    tmprmgraphicstart    
    wait               1
    tmprmgraphicend    
    wait               4
    tmprmgraphicstart    
    wait               1
    tmprmgraphicend    
    wait               3
    tmprmgraphicstart    
    wait               1
    tmprmgraphicend    
    wait               1
    tmprmgraphicstart    
    wait               1
    tmprmgraphicend    
    wait               1
    tmprmgraphicstart    
    wait               1
    goto               CommandCenterOverlayInit

CommandCenterOverlayDeath:
    wait               1
    end      

It's very simple. Create an overlay entry in images.dat that uses the nexus graphic. Then make the nexus use the overlay in the work script. Then copy the above script's code and use it in the nexus overlay's script.

Edit: I'm a bit late, lolz.
This post was edited 2 times, last edit by FlyingHat: May 31 2008, 10:06 pm.
Top

Post #47     A_of-s_t May 31 2008, 9:55 pm

[Avatar]
Master of Temptation, Ruler of Aeronotics, and Secret Lover
 offline contact
Terran buildings usuall have overlays when they are working. It might have to do with that -- however I've never tried it before.
From silent:
"lolol First of all wikipedia is flawed because anyone can come into it and post anything. About criticism.. no. You can't just change the definition of a word and expect everyone to bow down in awe. I am using macro evolution as an identifier between changing from one kind to another kind. I.E. bananas turning into flies. So if you want to argue about this then your argueing about the definition of a word.. Not the theory itself. If you want I can use false evolution, or neverbeenseenbefore evolution instead of macro. Its up to you"
This is stupidity. Please look at it very closely -- notice that almost every logical fallacy is used in it.
Top

Post #48     HailFire May 31 2008, 9:58 pm

[Avatar]
He's in ur base, killin' ur d00dz.
 offline contact
I'm trying to emulate the Barrack's work animation, which is frame-by-frame.

Also, I'd have to make my own overlay, which would be a hueg pain in the ass.
Top

Post #49     FlyingHat May 31 2008, 10:08 pm

[Avatar]
 offline contact
Quote from HailFire
Also, I'd have to make my own overlay, which would be a hueg pain in the ass.
Creating a new overlay is very simple, just edit a single images.dat entry and screw up some iscript.
Top

Post #50     ShadowFlare Jun 1 2008, 2:33 am

[Avatar]
 offline contact
Could it have anything to do with this?

Code

IsWorking           NexusIsWorking
WorkingToIdle       NexusIsWorking


WorkingToIdle is supposed to point to an idle script. You're basically telling it to continue the animation even when it is done with its work. Try changing NexusIsWorking back into a repeating animation and using NexusWalking for WorkingToIdle.

On a related note, does the Nexus normally have the "walking" animation or did you just add that in?
Top

Post #51     HailFire Jun 1 2008, 3:18 am

[Avatar]
He's in ur base, killin' ur d00dz.
 offline contact
Quote from ShadowFlare
Could it have anything to do with this?

Code

IsWorking           NexusIsWorking
WorkingToIdle       NexusIsWorking


WorkingToIdle is supposed to point to an idle script. You're basically telling it to continue the animation even when it is done with its work. Try changing NexusIsWorking back into a repeating animation and using NexusWalking for WorkingToIdle.

On a related note, does the Nexus normally have the "walking" animation or did you just add that in?

Win'd. It works perfectly now, I'm amazed I overlooked that. :lol:
Top

Post #52     HailFire Jun 1 2008, 3:20 am

[Avatar]
He's in ur base, killin' ur d00dz.
 offline contact
Quote from HailFire
Quote from ShadowFlare
Could it have anything to do with this?

Code

IsWorking           NexusIsWorking
WorkingToIdle       NexusIsWorking


WorkingToIdle is supposed to point to an idle script. You're basically telling it to continue the animation even when it is done with its work. Try changing NexusIsWorking back into a repeating animation and using NexusWalking for WorkingToIdle.

On a related note, does the Nexus normally have the "walking" animation or did you just add that in?

Win'd. It works perfectly now, I'm amazed I overlooked that. :lol:

Also, the "Walking" is artifical. It's what the CC had, and it's not like the nexus is going anywhere. :P

EDIT: Wow, I managed to hit quote instead of edit.

/fail :-(
Top

Post #53     ShadowFlare Jun 1 2008, 12:17 pm

[Avatar]
 offline contact
For future reference, you can have a label in the code that is only referenced from the code and not the header. This is where those "Local" labels come from -- because they aren't referenced in the header, the decompiler doesn't know what to call them (but you can call them what you want in your own code). The labels referenced in the header are only for parts of the animation where SC needs to know where they start.
Top
Users in this topic:


[08:59 pm]
[08:41 pm]
[Doodan]:] -- You can't stop Uwe Boll
[08:38 pm]
Psionic_Storm -- Dungeon Escape: new version available! - http://www.mediafire.com/?71vumk0yd6m
[08:13 pm]
[Doodan]:] -- *hides*
[08:10 pm]
Valug -- Valug is back for the day!
[08:10 pm]
Xx.Doom.xX -- Thank you Excalibur, I appreciate it. :)
You must log in to shout.

©2003-2008 Staredit Network.
Starcraft & Starcraft II are trademarks of Blizzard Entertainment.
Site Index   |   Terms of Service   |   Privacy Policy   |   Contributions