hejsil
  • hejsil
  • 53.75% (Neutral)
  • Private Topic Starter
15 years ago
I got a problem. i try to make a script that schould destroy a Superweapon if it have been build, but it is not going well. Here is what i got.

Script Destroy superweapon.
*** IF ***
'SW' has been built by Player ''
*** THEN ***
Unit ''is dealt a lethal amount of damage.

Script superweapon list.
*** IF ***
True.
*** THEN ***
'SW' : add 'AmericaParticleCannonUplink'
'SW' : add 'AirF_AmericaParticleCannonUplink'
'SW' : add 'Lazr_AmericaParticleCannonUplink'
'SW' : add 'SupW_AmericaParticleCannonUplink'
'SW' : add 'ChinaNuclearMissileLauncher'
'SW' : add 'Infa_ChinaNuclearMissileLauncher'
'SW' : add 'Tank_ChinaNuclearMissileLauncher'
'SW' : add 'Nuke_ChinaNuclearMissileLauncher'
'SW' : add 'GLAScudStorm'
'SW' : add 'Demo_GLAScudStorm'
'SW' : add 'Slth_GLAScudStorm'
'SW' : add 'GC_Slth_GLAScudStorm'
'SW' : add 'Chem_GLAScudStorm'
'SW' : add 'GC_Chem_GLAScudStorm'

can someone plzz find out what is wrong with this. But if you cant make a script like that i got an other question.
Sponsor
Annihilationzh
15 years ago
You can't make a script like that, unless there's some method no one knows of.
If you need help, post in the forum. You'll get help a lot faster than if you send me a PM.

I reject all buddy requests. I don't think 'buddy' needs to be made official. It's not like you're marrying me.
Drummin
15 years ago
Yes, defining 'SW' as an object type is fine but that's a general classification. So the condition of the script should work. The problem is that it is not a named unit but a class of units you've defined, so is unknown. In Tiberium Wars you set a reference to an unnamed object of type "SW" and give it a name such as BYESW. Then your damage script can work for the named object BYESW. Unfortunately, Zero Hour doesn't have a script to set a reference. I guess you're stuck with just modifying the "Tech Tree" to Disallow super weapons (under Map/Modify).
hejsil
  • hejsil
  • 53.75% (Neutral)
  • Private Topic Starter
15 years ago
:(
When i got an other quetion when i make a map.ini with a code that should make so you cant use superweapon i get a problem. It works fin in skimish, BUT when i got to multiplay with one of my friends in this map he can build superweapon but i cant, but when he try to build it the game get an error. Any of you know why that happen.
Drummin
15 years ago
Use the script like I mentioned in the PlyrCivilian folder instead of a map.ini file.
hejsil
  • hejsil
  • 53.75% (Neutral)
  • Private Topic Starter
15 years ago
I have read my own post, i whould not understand it if i was you so im trying again. I make a map.ini with this:
Object ChinaNuclearMissileLauncher
Buildable = No
END

Object Tank_ChinaNuclearMissileLauncher
Buildable = No
END

Object Nuke_ChinaNuclearMissileLauncher
Buildable = No
END

Object Infa_ChinaNuclearMissileLauncher
Buildable = No
END

Object AmericaParticleCannonUplink
Buildable = No
END

Object SupW_AmericaParticleCannonUplink
Buildable = No
END

Object Lazr_AmericaParticleCannonUplink
Buildable = No
END

Object AirF_AmericaParticleCannonUplink
Buildable = No
END

Object GLAScudStorm
Buildable = No
END

Object Slth_GLAScudStorm
Buildable = No
END

Object Demo_GLAScudStorm
Buildable = No
END

Object Chem_GLAScudStorm
Buildable = No
END

When i play in skimish it work fin but when i play it with my friend online hecan build a superweapon and i cant (we was the same general), but when he try to build it the game get an error and we D/C. You guys know why this happen.
Annihilationzh
15 years ago
Because your friend's game isn't running the map.ini. It's a standard issue with map.inis. That's why drummin told you to use a script.
If you need help, post in the forum. You'll get help a lot faster than if you send me a PM.

I reject all buddy requests. I don't think 'buddy' needs to be made official. It's not like you're marrying me.
hejsil
  • hejsil
  • 53.75% (Neutral)
  • Private Topic Starter
15 years ago
Oh ok, but i cant find the scripts for it anywhere 😞
Annihilationzh
15 years ago
From Drummin

I guess you're stuck with just modifying the "Tech Tree" to Disallow super weapons (under Map/Modify).


Map>modify>Adjust the tech tree...
If you need help, post in the forum. You'll get help a lot faster than if you send me a PM.

I reject all buddy requests. I don't think 'buddy' needs to be made official. It's not like you're marrying me.
hejsil
  • hejsil
  • 53.75% (Neutral)
  • Private Topic Starter
15 years ago
Thanks for all the help 😁 👍 👍