Trigger_flagonly_multiple scripting


(-SSF-Sage) #21

Well debug it. Like this for example:

	trigger move_to_159
	{
wm_announce "a"
		trigger self wheels_forward
		accum 3 bitset 3
		followspline 0 path_158 100 wait length -64
		accum 3 bitreset 3
		trigger self wheels_stop
wm_announce "b"
                trigger game_manager end
	}

(Destroy666) #22

I did like I said - I added two splines more and put the trigger game_manager at the script beggining of the first added spline. It worked.

The commandmap marker truck is showing.
I mean the objectives commandmap marker.
It points at trigger objective info (pizzamarker_toi)

pizzamarker_toi
{
       spawn
       {
               wait 200
       }
       trigger remove
       {
               remove
       }
}

pizzadeliverypoint
{
       spawn
       {
               wait 200
               accum 1 set 0
               trigger truck nopizzas
       }       

       death
       { 
               accum 1 inc 1
               accum 1 abort_if_not_equal 4 
               trigger pizzamarker_toi remove
               setstate cm_pizza invisible
               wm_announce "Allies have stolen all pizzas and brought them to the Truck"
               trigger truck allpizzas

               wm_objective_status 2 0 2
               wm_objective_status 2 1 1
       }
}

(Destroy666) #23

Next problem - how to disable stealing objective before xxx happens?
I tried:

  1. Setstate objective - doesn’t work
  2. Globalaccums, I tried adding:

game_manager
{
          globalaccum 1 set 1
}

pizza1 (and other)
{
         spawn
         {
         globalaccum 1 abort_if_not_equal 2
         }
}

truck
{
        trigger move_to_39
        {
        globalaccum 1 set 2
        }
}

and


game_manager
{
          globalaccum 1 set 1
}

pizza1 (and other)
{
         trigger stolen
         {
         globalaccum 1 abort_if_not_equal 2
         }
}

truck
{
        trigger move_to_39
        {
        globalaccum 1 set 2
        }
}

Doesn’t work too

How can I do it?


(masterkiller) #24

maybe whit a fake model…(game_misc_model)

something like this:


pizza1_mdl
{
         spawn
         {
         }

         trigger remove
         {
               setstate pizza1_mdl invisible
         }
}



truck
{
        trigger move_to_39
        {
        trigger pizza1_mdl remove
        alertentity  pizza1
        }
}

if you dont need fake model at spawn , just use alertentity pizza1 (targetname of team_CTF_XX)


(Destroy666) #25

Thanks and Happy New Year!

I faked models with func_static.
Setstate didn’t work because I didn’t set targetname.

I found this:
“targetname” do ->NOT<- set this, it will cause problems
in et_entities.def
Which problems will it cause?

And does anyone know how to solve this with my truck model position and commandmap icon?


(Zer0Cool) #26

I found this:
“targetname” do ->NOT<- set this, it will cause problems
in et_entities.def
Which problems will it cause?

mabyby you should have mentioned that it is for team_CTF_redflag and team_CTF_blueflag.
iirc when you use targetnames, you will have to use the command “alertentity <targetname>” to spawn the flag.


(Destroy666) #27

I tried now to make my own truck model with C’s .map to .md3 convert tool.
Effect is that clipping is done good, but how to fix that?

It’s rotated incorrect and too much down