migidu
02-12-2008, 5:06 AM
In this tutorial i will show you how to make a new weapon. Let us first define NEW. New means something you don't usually see in the game itself. and it does not mean adding a new entry in the game because you can never do that. all you can do is alter the existing ones. :)
Tools needed:
-Firegraft 0.93
-Icecc
-Datedit1.5
-WinMPQ
Note: you should have basic knowledge on how to use these tools and the updated version of them:)
1. CHOOSE A BASE GRAPHICS
- it should be among the flingy files. you may open up datedit to check which files they are by browsing the flingy tab. in this tutorial we will use the Generator.grp. I use this grp because i wont be needing it in the maps.
- Choose another grp you want the base grp to be. this may be a custom graphics or a graphics already in the starcraft game. this will be the "new weapon". :D in this tutorial we will use the High Templar glow. Open StarDat.mpq with WinMPQ to extract it. It is unit\thingy\pteglow.grp. Now rename it as "Generator.grp" .
- If you do not know where to find your files open datedit and go to the flingy, sprites or image tab to search the sprite file, imagefile or GRP file and iscript ID. Now we are done in the graphics.
2. TIME TO ISCRIPT
- iscripting isnt really hard to understand. there's the header then some block of codes which has opcodes and parameters. you can easily identify them.
- find the power generator iscript id. it is "949 Power Generater" in the image tab and "496 Unknown216" in the sprites tab. Again you should know how to use Icecc. :)
- open another iscript file which is a weapon graphics in starcraft already like yamato gun (350 Unknown75) under sprites tab or phase disruptor (337 Phase Disruptor) under sprites tab. I choose phase disruptor.
- Here you will notice the difference in their header :
# This header is used by images.dat entries:
# 949 PowerGenerater (neutral\Generate.grp)
.headerstart
IsId 408
Type 20
Init PowerGeneratorInit
Death PowerGeneratorDeath
GndAttkInit [NONE]
AirAttkInit [NONE]
Unused1 [NONE]
GndAttkRpt [NONE]
AirAttkRpt [NONE]
CastSpell [NONE]
GndAttkToIdle [NONE]
AirAttkToIdle [NONE]
Unused2 [NONE]
Walking [NONE]
WalkingToIdle [NONE]
SpecialState1 [NONE]
SpecialState2 [NONE]
AlmostBuilt [NONE]
Built PowerGeneratorBuilt
Landing [NONE]
LiftOff [NONE]
IsWorking PowerGeneratorIsWorking
WorkingToIdle PowerGeneratorIsWorking
WarpIn [NONE]
.headerend
# This header is used by images.dat entries:
# 523 PhaseDisruptor (bullet\dragbull.grp)
.headerstart
IsId 234
Type 2
Init PhaseDisruptorInit
Death PhaseDisruptorDeath
GndAttkInit PhaseDisruptorGndAttkInit
AirAttkInit [NONE]
.headerend
- to make your base graphics behave like the phase disruptor it should have the same header. same for making a weapon bounce, it should have the same header as glave wurm.
-change the header of the power generator to this :
# This header is used by images.dat entries:
# 949 PowerGenerater (neutral\Generate.grp)
.headerstart
IsId 408
Type 2
Init PowerGeneratorInit
Death PowerGeneratorDeath
GndAttkInit PowerGeneratorGndAttkInit
AirAttkInit [NONE]
.headerend
- now we change the block of codes. this is what it should look like :
PowerGeneratorInit:
playsnd 99 # Bullet\DragBull.wav
wait 1
sigorder 1
wait 1
PowerGeneratorGndAttkInit:
playfram 0
wait 1
playfram 17
wait 1
playfram 34
wait 1
goto PowerGeneratorGndAttkInit
PowerGeneratorDeath:
wait 1
domissiledmg
wait 1
end
- notice how i modified the block of codes. this is the original :
PowerGeneratorInit:
imgul 950 0 0 # PowerGeneraterShad (neutral\tgnShad.grp)
PowerGeneratorBuilt:
playfram 0
wait 2
playfram 1
wait 2
playfram 2
wait 2
playfram 3
wait 2
playfram 4
wait 2
playfram 5
wait 2
playfram 6
wait 2
goto PowerGeneratorBuilt
PowerGeneratorDeath:
playsnd 7 # Misc\ExploLrg.wav
imgol 334 0 0 # TerranBuildingExplosionlarge (thingy\tBangX.grp)
wait 3
liftoffcondjmp PowerGeneratorLocal00
lowsprul 273 0 0 # TerranBuildingRubblesmall (thingy\RubbleS.grp)
wait 1
end
PowerGeneratorLocal00:
wait 1
end
PowerGeneratorIsWorking:
wait 125
goto PowerGeneratorIsWorking
- the basis for how the block of codes should look like is from the phase disruptor :
PhaseDisruptorInit:
playsnd 99 # Bullet\DragBull.wav
wait 1
sigorder 1
wait 1
PhaseDisruptorGndAttkInit:
playfram 0
wait 1
playfram 1
wait 1
playfram 2
wait 1
playfram 3
wait 1
playfram 4
wait 1
goto PhaseDisruptorGndAttkInit
PhaseDisruptorDeath:
imgol 427 0 0 # Unknown427 (thingy\HKexplod.grp)
domissiledmg
wait 1
end
- how did i know what frames to play ? i searched up the frames of the high templar glow (449 High Templar Trail) under image tab.
HighTemplarGlowInit:
playfram 0x00 # frame set 0
wait 2
playfram 0x11 # frame set 1
wait 2
playfram 0x22 # frame set 2
wait 2
end
- and modified it to this :
PowerGeneratorGndAttkInit:
playfram 0
wait 1
playfram 17
wait 1
playfram 34
wait 1
goto PowerGeneratorGndAttkInit
-compile it with iscript.bin. now we're done with the iscripting part. :)
3. USING THE WEAPON
- open up datedit. search for tassadar high templar. when you find the psi assault in the weapons flag, click "jump" or just go to the weapons tab and find weapon "69 Psi Assault (Aldaris + Tassadar)". there, change the graphics flag to "196" or "power generator". And behaviour to "Fly to target". Now psi assault will use the this properties. go to file, choose "save as" then press enter.
Note: you could edit more with your own weapon. datedit provides much options
- go to the flingy tab. find phase disruptor. right click it and choose "copy entry". find power generator. right click and choose "paste entry". now change the sprite file to "496" or "power generator". This just made things easier so you dont have to think of the values for topspeed, acceleration, halt distance, and turn radius.
Note: You should not forget this since this step allows the graphics to have the move control as "partially mobile,weapon". go to file, choose "save as" then press enter.
4. COMPILING
- i use firegraft to make SEMPQs. also here you could do some additional grafting. as i said this was just to make an SEMPQ. click new then save as what you like. ill save mine as "new".
-now open up winmpq. open new.exe. add the new graphics "Generator.grp" with the exact address "unit\neutral\".
Note : it is very important you have the correct names.
- add the the weapons.dat with "arr\" and flingy.dat with "arr\" and the iscript.bin with "scripts\" you just made. :)
CONGRATULATIONS. YOU'VE JUST MADE TASSADAR ATTACK WITH HIGH TEMPLAR GLOW. CHECK IT OUT ON THE FILE BELOW. :beer:
here's the sample mod. uh, it's for 1.15.1 only
note: to build tassadar, it requires an observatory :D
Tools needed:
-Firegraft 0.93
-Icecc
-Datedit1.5
-WinMPQ
Note: you should have basic knowledge on how to use these tools and the updated version of them:)
1. CHOOSE A BASE GRAPHICS
- it should be among the flingy files. you may open up datedit to check which files they are by browsing the flingy tab. in this tutorial we will use the Generator.grp. I use this grp because i wont be needing it in the maps.
- Choose another grp you want the base grp to be. this may be a custom graphics or a graphics already in the starcraft game. this will be the "new weapon". :D in this tutorial we will use the High Templar glow. Open StarDat.mpq with WinMPQ to extract it. It is unit\thingy\pteglow.grp. Now rename it as "Generator.grp" .
- If you do not know where to find your files open datedit and go to the flingy, sprites or image tab to search the sprite file, imagefile or GRP file and iscript ID. Now we are done in the graphics.
2. TIME TO ISCRIPT
- iscripting isnt really hard to understand. there's the header then some block of codes which has opcodes and parameters. you can easily identify them.
- find the power generator iscript id. it is "949 Power Generater" in the image tab and "496 Unknown216" in the sprites tab. Again you should know how to use Icecc. :)
- open another iscript file which is a weapon graphics in starcraft already like yamato gun (350 Unknown75) under sprites tab or phase disruptor (337 Phase Disruptor) under sprites tab. I choose phase disruptor.
- Here you will notice the difference in their header :
# This header is used by images.dat entries:
# 949 PowerGenerater (neutral\Generate.grp)
.headerstart
IsId 408
Type 20
Init PowerGeneratorInit
Death PowerGeneratorDeath
GndAttkInit [NONE]
AirAttkInit [NONE]
Unused1 [NONE]
GndAttkRpt [NONE]
AirAttkRpt [NONE]
CastSpell [NONE]
GndAttkToIdle [NONE]
AirAttkToIdle [NONE]
Unused2 [NONE]
Walking [NONE]
WalkingToIdle [NONE]
SpecialState1 [NONE]
SpecialState2 [NONE]
AlmostBuilt [NONE]
Built PowerGeneratorBuilt
Landing [NONE]
LiftOff [NONE]
IsWorking PowerGeneratorIsWorking
WorkingToIdle PowerGeneratorIsWorking
WarpIn [NONE]
.headerend
# This header is used by images.dat entries:
# 523 PhaseDisruptor (bullet\dragbull.grp)
.headerstart
IsId 234
Type 2
Init PhaseDisruptorInit
Death PhaseDisruptorDeath
GndAttkInit PhaseDisruptorGndAttkInit
AirAttkInit [NONE]
.headerend
- to make your base graphics behave like the phase disruptor it should have the same header. same for making a weapon bounce, it should have the same header as glave wurm.
-change the header of the power generator to this :
# This header is used by images.dat entries:
# 949 PowerGenerater (neutral\Generate.grp)
.headerstart
IsId 408
Type 2
Init PowerGeneratorInit
Death PowerGeneratorDeath
GndAttkInit PowerGeneratorGndAttkInit
AirAttkInit [NONE]
.headerend
- now we change the block of codes. this is what it should look like :
PowerGeneratorInit:
playsnd 99 # Bullet\DragBull.wav
wait 1
sigorder 1
wait 1
PowerGeneratorGndAttkInit:
playfram 0
wait 1
playfram 17
wait 1
playfram 34
wait 1
goto PowerGeneratorGndAttkInit
PowerGeneratorDeath:
wait 1
domissiledmg
wait 1
end
- notice how i modified the block of codes. this is the original :
PowerGeneratorInit:
imgul 950 0 0 # PowerGeneraterShad (neutral\tgnShad.grp)
PowerGeneratorBuilt:
playfram 0
wait 2
playfram 1
wait 2
playfram 2
wait 2
playfram 3
wait 2
playfram 4
wait 2
playfram 5
wait 2
playfram 6
wait 2
goto PowerGeneratorBuilt
PowerGeneratorDeath:
playsnd 7 # Misc\ExploLrg.wav
imgol 334 0 0 # TerranBuildingExplosionlarge (thingy\tBangX.grp)
wait 3
liftoffcondjmp PowerGeneratorLocal00
lowsprul 273 0 0 # TerranBuildingRubblesmall (thingy\RubbleS.grp)
wait 1
end
PowerGeneratorLocal00:
wait 1
end
PowerGeneratorIsWorking:
wait 125
goto PowerGeneratorIsWorking
- the basis for how the block of codes should look like is from the phase disruptor :
PhaseDisruptorInit:
playsnd 99 # Bullet\DragBull.wav
wait 1
sigorder 1
wait 1
PhaseDisruptorGndAttkInit:
playfram 0
wait 1
playfram 1
wait 1
playfram 2
wait 1
playfram 3
wait 1
playfram 4
wait 1
goto PhaseDisruptorGndAttkInit
PhaseDisruptorDeath:
imgol 427 0 0 # Unknown427 (thingy\HKexplod.grp)
domissiledmg
wait 1
end
- how did i know what frames to play ? i searched up the frames of the high templar glow (449 High Templar Trail) under image tab.
HighTemplarGlowInit:
playfram 0x00 # frame set 0
wait 2
playfram 0x11 # frame set 1
wait 2
playfram 0x22 # frame set 2
wait 2
end
- and modified it to this :
PowerGeneratorGndAttkInit:
playfram 0
wait 1
playfram 17
wait 1
playfram 34
wait 1
goto PowerGeneratorGndAttkInit
-compile it with iscript.bin. now we're done with the iscripting part. :)
3. USING THE WEAPON
- open up datedit. search for tassadar high templar. when you find the psi assault in the weapons flag, click "jump" or just go to the weapons tab and find weapon "69 Psi Assault (Aldaris + Tassadar)". there, change the graphics flag to "196" or "power generator". And behaviour to "Fly to target". Now psi assault will use the this properties. go to file, choose "save as" then press enter.
Note: you could edit more with your own weapon. datedit provides much options
- go to the flingy tab. find phase disruptor. right click it and choose "copy entry". find power generator. right click and choose "paste entry". now change the sprite file to "496" or "power generator". This just made things easier so you dont have to think of the values for topspeed, acceleration, halt distance, and turn radius.
Note: You should not forget this since this step allows the graphics to have the move control as "partially mobile,weapon". go to file, choose "save as" then press enter.
4. COMPILING
- i use firegraft to make SEMPQs. also here you could do some additional grafting. as i said this was just to make an SEMPQ. click new then save as what you like. ill save mine as "new".
-now open up winmpq. open new.exe. add the new graphics "Generator.grp" with the exact address "unit\neutral\".
Note : it is very important you have the correct names.
- add the the weapons.dat with "arr\" and flingy.dat with "arr\" and the iscript.bin with "scripts\" you just made. :)
CONGRATULATIONS. YOU'VE JUST MADE TASSADAR ATTACK WITH HIGH TEMPLAR GLOW. CHECK IT OUT ON THE FILE BELOW. :beer:
here's the sample mod. uh, it's for 1.15.1 only
note: to build tassadar, it requires an observatory :D