Hi all,
How do I disable the destruction of a constructible object in script?
I want to disable it after a certain thing happens (after an object is captured), so I cannot use the spawnflag…
Hi all,
How do I disable the destruction of a constructible object in script?
I want to disable it after a certain thing happens (after an object is captured), so I cannot use the spawnflag…
On “destroyed event”, just skip the “enable constructible” event 
If you need an example, just copy/paste the related script part here (Don’t forget the
around :P).
You could use a globalaccum.
If you have to test more conditions you could use bitset to set bits of this globalaccum.
In addition you could also create a decoy model. Setstate it to invisible at mapstart in spawn{} of game_manager:
setstate <targetname> invisible
When obj captured:
setstate <targetname> default
do setstate invisible the func_constructible. Or create nothing and just setstate everything invisible.
P.S. i believe in normal mapscripting you cannot change classname of entity, but you could try set it to 0 
In addition you could also create a decoy model (script_mover). Setstate it to invisible at mapstart in spawn{} of game_manager:
setstate <targetname> invisible
When obj captured:
setstate <targetname> default
and do setstate invisible the func_constructible. Or create nothing and just setstate everything invisible.
P.S. i believe in normal mapscripting you cannot change classname or constructible class of entity … 
EDIT: or try if it works as a tank xD => http://games.chruker.dk/enemy_territory/scripting_reference.php#tank_related Look for “setdamagable <targetname> <status>” and try destroying it after you have used this command.
Also you could just hide the construction materials hehe. If it is destroyed at least it can not be constructed anymore. But if you want to have it visible after obj captured, then i believe you must create a decoy.
Hmm I misunderstood the post, sorry >.>
So just built one? It’s like a normal constructible, but nothing enabled to make it destructible, should be all?
Edit:
For condition, accum is need ofc as acQu explained 
game_manager -> accum 1 set 0
Flag_secured -> accum 1 set 1
Obj_built -> accum 1 abort_if_not_equal 0 -> Set damageable
Also ensure if the thingy is already built that on Flag_secured you disable its “damageability”.
[QUOTE=Mateos;411985]Hmm I misunderstood the post, sorry >.>
So just built one? It’s like a normal constructible, but nothing enabled to make it destructible, should be all?[/QUOTE]
He should have a func_constructible entity. I believe in my tryings a constructible_class <construction_class> with construction_class = 0 never worked, so i believe you must work around this with decoy model or possibly other stuff.
But why doing it anyway. Let it be built and destroyed till they go crazy 
[QUOTE=Mateos;411985]Hmm I misunderstood the post, sorry >.>
So just built one? It’s like a normal constructible, but nothing enabled to make it destructible, should be all?
Edit:
For condition, accum is need ofc as acQu explained 
game_manager -> accum 1 set 0
Flag_secured -> accum 1 set 1
Obj_built -> accum 1 abort_if_not_equal 0 -> Set damageable
Also ensure if the thingy is already built that on Flag_secured you disable its “damageability”.[/QUOTE]
Does the set damagable stuff really work O-o 
[QUOTE=acQu;411986]He should have a func_constructible entity. I believe in my tryings a constructible_class <construction_class> with construction_class = 0 never worked, so i believe you must work around this with decoy model or possibly other stuff.
But why doing it anyway. Let it be built and destroyed till they go crazy :-P[/QUOTE]
yeah i tried constructible_class 0… doesn’t work
lol… the problem is that the axis have to capture some sausages and put them on a destructible barbeque. if the barbeque is destroyed after the sausages are captured, there are some floating sausages -_-
I dont need accums, because all i want to do is stop the func_constructible barbeque being destroyed when the sausages are captured, so i just put the code in the sausages{ captured{} } event.
this is what i want:
sausages
{
trigger captured
{
//CODE HERE TO DISABLE DESTRUCTION OF BARBEQUE...WHAT IS THE CODE?????
}
}
so do i have to make 2 barbeques and show the non-destructible one after the sausages are captured or is there a better way?
[QUOTE=Mateos;411985]Hmm I misunderstood the post, sorry >.>
So just built one? It’s like a normal constructible, but nothing enabled to make it destructible, should be all?
Edit:
For condition, accum is need ofc as acQu explained 
game_manager -> accum 1 set 0
Flag_secured -> accum 1 set 1
Obj_built -> accum 1 abort_if_not_equal 0 -> Set damageable
Also ensure if the thingy is already built that on Flag_secured you disable its “damageability”.[/QUOTE]
well, the flag can only be captured if this particular func_constructible is built, so all i need to do is disable the func_constructible’s “damageability” when the flag is captured (the func_constructible starts off damageable)… my question is HOW do i disable its “damageability”?
ET does not recognise the command “setdamageable”
[QUOTE=acQu;411983]In addition you could also create a decoy model (script_mover). Setstate it to invisible at mapstart in spawn{} of game_manager:
setstate <targetname> invisible
When obj captured:
setstate <targetname> default
and do setstate invisible the func_constructible. Or create nothing and just setstate everything invisible.
P.S. i believe in normal mapscripting you cannot change classname or constructible class of entity … 
EDIT: or try if it works as a tank xD => http://games.chruker.dk/enemy_territory/scripting_reference.php#tank_related Look for “setdamagable <targetname> <status>” and try destroying it after you have used this command.
Also you could just hide the construction materials hehe. If it is destroyed at least it can not be constructed anymore. But if you want to have it visible after obj captured, then i believe you must create a decoy.[/QUOTE]
whats the difference between func_static and script_mover?
here http://wiki.splashdamage.com/index.php/Wolfenstein:_Enemy_Territory it says to use func_static, but i think that is wrong. why cant i use func_static? it works…
[QUOTE=BMW;411995]this is what i want:
sausages
{
trigger captured
{
//CODE HERE TO DISABLE DESTRUCTION OF BARBEQUE...WHAT IS THE CODE?????
}
}
so do i have to make 2 barbeques and show the non-destructible one after the sausages are captured or is there a better way?[/QUOTE]
The command you use is just “setstate invisible” or “setstate default”. Don’t forget to give your entities that targetname in radiant in entity window. I have the following targetnames: “barbeque_decoy” for the decoy model, “barbeque” for the construction, “barbeque_construction_materials” for the visible construction materials and “barbeque_construction_materials_toi” for the invisible construction materials (those which actually construct), aaand maybe there is some i forgot xD
Then, after your targetnames in Radiant are set you can use this script and write into capture event:
sausages
{
trigger captured
{
setstate barbeque_decoy default
setstate barbeque invisible
setstate barbeque_construction_materials invisible
setstate barbeque_construction_materials_toi invisible
}
}
Dont forget to set in game_manager in spawn event this:
setstate barbeque_decoy invisible
[QUOTE=BMW;411998]whats the difference between func_static and script_mover?
here http://wiki.splashdamage.com/index.php/Wolfenstein:_Enemy_Territory it says to use func_static, but i think that is wrong. why cant i use func_static? it works…[/QUOTE]
I guess func_static is also ok.
Have fun. Will you release the barbeque map ?
I sure would want to give it a try 
I like sausages, too. 
Well, if you can’t disable the fast it is damageable, you may keep the damageable thingy disabled and do a setstate other_mover default, in which other_mover will be a mover and only a mover?
ok thanks guys, ill use the decoy idea.
ill chunk a link to the alpha version on shortly
here u go 
please give me some feedback on it!!
EDIT: you can also download omnibot waypoints for the map here:
http://svn.assembla.com/svn/omnibot/Enemy-Territory/0.8/et/incomplete_navs/with_script/
Hello,
Sorry to bump a (quite) old thread, but I kept this attached to my web browser since the feedback request, and now I have some spare time I’ve tested it and here you go 
http://mateos.picturepush.com/album/267916/p-Beach-BBQ-Beta-1-Feedback.html
Most of shots are for flying objects; Bottom of walls when inside the terrain should be caulked.
The panel which can be satchel’d does not have a command map icon, BBQ as well (Dropoff should have it for easier navigation for attack/defense). You could also add voice announcements for build objectives 
The objective house has a single exit for Axis, sounds like a bottleneck
In the same house, the heal value of the cab is too high IMHO. And when Axis have past the first great walls, they’re almost safe 
Doors open quite slowly.
The screenshot with white lines is about T-Junctions; The brush above the door, you should move the top left edge to the top left of the whole building face, and some for other side, would generate less triangles to display
More details here.
And well if you want something advance, I would advice you to try this for the terrain:
http://simonoc.com/pages/articles/terrain2_1.htm
With sand under/front of water, some rocky/grassy surfaces here and there, it would look awesome!
Also please fill a bit the space if you can 
Nice map! 
Edit: About making Command Map icons, there were a good tutorial by IndyJones on his website, but it is gone and Wayback Machine has no snapshot… 