hi,
I already read that there is a bug when i want to hide/unhide a team_ctf_red/blueflag. This is what I did:
- Added team_ctf_redflag with target+scriptname: rocketcontrol
- Added alertentity rocketcontrol to the game_manager spawn part (script at the end)
- used setstate in the later script
But now I get the following error message:
G_scripting alertentity “rocketcontrol” (classname = team_ctf_redflag) doesn’t have a “use” function
I have no idea what I did wrong… So here you get all the necessary parts of my script:
game_manager
{
spawn
{
wm_axis_respawntime 30
wm_allied_respawntime 20
wm_set_round_timelimit 15
wm_number_of_objectives 5
wm_setwinner 0
setautospawn "Bunker Spawn" 1
setautospawn "Forward Bunker Spawn" 0
alertentity rocketcontrol
trigger game_manager setstatesoff
setstate rocketcontrol invisible
}
...
}
...
glotz
{
spawn
{
wait 200
trigger self setup
constructible_class 3
}
trigger setup
{
setstate glotz invisible
setstate baumaterial_toi default
setstate baumaterial default
setstate baumaterial_mod default
}
buildstart final
{
setstate glotz underconstruction
alertentity glotzfake
setstate baumaterial default
setstate baumaterial_mod default
}
built final
{
setstate glotz invisible
setstate baumaterial invisible
setstate baumaterial_mod invisible
setstate rocketcontrol default
wm_announce "The Rocket Controls have been dismantled."
}
decayed final
{
setstate glotz invisible
alertentity glotzfake
setstate baumaterial default
setstate baumaterial_mod default
}
death
{
}
}
...
rocketcontrol
{
spawn
{
}
trigger stolen
{
wait 1000
// *----------------------------------- vo ------------------------------------------*
//wm_teamvoiceannounce 0 "radar_axis_radarw_taken"
//wm_teamvoiceannounce 1 "radar_allies_radarw_taken"
// *---------------------------------------------------------------------------------*
}
trigger returned
{
// *----------------------------------- vo ------------------------------------------*
//wm_teamvoiceannounce 0 "radar_axis_radarw_returned"
//wm_teamvoiceannounce 1 "radar_allies_radarw_returned"
// *---------------------------------------------------------------------------------*
}
trigger captured
{
trigger truckbox2 visible
trigger truckboxtrans2 invisible
// Allies win
}
}
Please help me out with this.
eiM