Site  •  Wiki  •  FAQ  •  Login

Unit won't cast spell

<<

ForTheSwarm

User avatar

Posts: 26

Joined: July 13th, 2009, 11:45 am

Post July 16th, 2009, 5:54 pm

Unit won't cast spell

I have an unit that can fire an RPG as a spell. The technology it is supposed to use is Psi Storm, but it doesn't actually cast Psi Storm: in the CastSpell portion of the iscript, castspell is replaced with attackwith2 . However, the unit will occasionally not respond to orders to use the spell. I click on the button and then on the target, but the unit does not respond.

HELP!
Live for the Swarm...
<<

Hydrolisk

User avatar

Posts: 165

Joined: June 17th, 2009, 2:42 pm

Location: Peak of the spire.

Post July 16th, 2009, 6:37 pm

Re: Unit won't cast spell

You might want to check the orders.dat file, and post the iscript of the unit, too. Maybe checking the FG requirements will reveal the problem.
<<

ForTheSwarm

User avatar

Posts: 26

Joined: July 13th, 2009, 11:45 am

Post July 16th, 2009, 7:00 pm

Re: Unit won't cast spell

I didn't find anything in orders.dat that would help, and I've triple-checked the FG requirements.

Here is the iscript:

Spoiler: show
# ----------------------------------------------------------------------------- #
# This is a decompile of the iscript.bin file 'data\scripts\iscript.bin'
# created on: Fri Jan 16 10:13:47 2009
# ----------------------------------------------------------------------------- #

# ----------------------------------------------------------------------------- #
# This header is used by images.dat entries:
# 237 KerriganGhost (terran\ughost.grp)
.headerstart
IsId 77
Type 13
Init SarahKerriganInit
Death SarahKerriganDeath
GndAttkInit SarahKerriganGndAttkInit
AirAttkInit SarahKerriganGndAttkInit
Unused1 [NONE]
GndAttkRpt SarahKerriganGndAttkRpt
AirAttkRpt SarahKerriganGndAttkRpt
CastSpell SarahKerriganCastSpell
GndAttkToIdle SarahKerriganLocal00
AirAttkToIdle SarahKerriganLocal00
Unused2 [NONE]
Walking SarahKerriganWalking
WalkingToIdle SarahKerriganWalkingToIdle
SpecialState1 SarahKerriganSpecialState1
.headerend
# ----------------------------------------------------------------------------- #

SarahKerriganInit:
imgul 945 0 30 # MedicShad (terran\tmeShad.grp)
SarahKerriganLocal01:
playfram 0x00 # frame set 0
SarahKerriganLocal02:
setvertpos 1
waitrand 8 10
setvertpos 2
waitrand 8 10
setvertpos 1
waitrand 8 10
setvertpos 0
waitrand 8 10
setvertpos 1
waitrand 8 10
setvertpos 2
waitrand 8 10
setvertpos 1
waitrand 8 10
setvertpos 0
waitrand 8 10
goto SarahKerriganLocal02

SarahKerriganDeath:
playsndbtwn 11 12 # Misc\Explo2.WAV, Misc\Explo3.WAV
imgol 332 0 0 # TerranBuildingExplosionsmall (thingy\tBangS.grp)
wait 3
end

SarahKerriganGndAttkInit:
playfram 0x00 # frame set 0
wait 1
playfram 0x11 # frame set 1
wait 1
playfram 0x22 # frame set 2
SarahKerriganGndAttkRpt:
wait 1
nobrkcodestart
playfram 0x44 # frame set 4
wait 1
attackwith 1
playfram 0x55 # frame set 5
wait 1
playfram 0x44 # frame set 1
wait 1
playfram 0x33 # frame set 3
nobrkcodeend
gotorepeatattk
ignorerest
SarahKerriganLocal00:
wait 1
SarahKerriganGndAttkToIdle:
playfram 0x22 # frame set 2
wait 1
playfram 0x11 # frame set 1
wait 1
playfram 0x00 # frame set 0
wait 1
goto SarahKerriganWalkingToIdle

SarahKerriganCastSpell:
nobrkcodestart
playfram 0x11 # frame set 1
wait 3
playfram 0x22 # frame set 2
attackwith 2
sigorder 2
wait 3
playfram 0x11 # frame set 1
wait 3
nobrkcodeend
gotorepeatattk
playfram 0x00 # frame set 0
goto SarahKerriganLocal03

SarahKerriganLocal03:
wait 125
goto SarahKerriganLocal03

SarahKerriganWalking:
playfram 0xcc # frame set 12
wait 125
goto SarahKerriganWalking

SarahKerriganWalkingToIdle:
orderdone 1
goto SarahKerriganLocal01

SarahKerriganSpecialState1:
playfram 0x33 # frame set 3
wait 1

SarahKerriganLocal04:
sigorder 1
playfram 0x44 # frame set 4
wait 1
playfram 0x55 # frame set 5
wait 1
playfram 0x44 # frame set 4
wait 1
playfram 0x55 # frame set 5
wait 1
playfram 0x44 # frame set 4
wait 1
playfram 0x55 # frame set 5
wait 1
playfram 0x44 # frame set 4
wait 1
playfram 0x55 # frame set 5
wait 1
playsnd 1018 # Terran\Medic\TMedHeal.wav
goto SarahKerriganLocal04
Live for the Swarm...
<<

AofST

User avatar

Posts: 183

Joined: June 7th, 2009, 9:53 pm

Location: In the End of the World News

Post July 16th, 2009, 7:20 pm

Re: Unit won't cast spell

Try removing the sigorder.
Try using another value for the sigorder.
Make sure that the original psistorm did not have any code that would affect the unit.
Support my new site:
http://ideabirth.co.cc/
<<

ForTheSwarm

User avatar

Posts: 26

Joined: July 13th, 2009, 11:45 am

Post July 16th, 2009, 7:58 pm

Re: Unit won't cast spell

Messing with sigorder has no effect.

What kind of code?
Live for the Swarm...

Return to Help!

Who is online

Users browsing this forum: No registered users and 1 guest

cron
phpBBST Software