[airstrike] Triggers and level ending

Eero Tamminen eero.tamminen at netsonic.fi
Wed Jul 13 16:34:54 EDT 2005


Hi,

On Wednesday 13 July 2005 12:07, Erik Auerswald wrote:
> > > What should happen when plane dies?
> >
> > There should be some number of "lives", I think.

The number of lives is set with the player generator object count.
	generator player biplane 100 500 3 objtag=p1plane
means three lives before player is marked dead.  Dead means that
the generator won't spawn any more player biplanes.


> > For single player you shouldn't go to the next level unless the current
> > one is done (whatever that means),

How do you define single-player?

Currently level files could e.g. define four biplanes for each level, but
unless on command line they are given AIs, they will have the dummy
"koala" AIs, and just idle at their starting point.  :-)


> > but for multiplayer dogfight I think that we 
> > can change level after some number of deaths.
>
> I second that. After using up every "life" in single player resp.
> cooperative multi player mode the level should restart IMO.
>
> For deathmatch style dogfighting a time- and/or fraglimit could be used
> to change levels.

With triggers it's possible to do this on per level bases.
	trigger level-done timer 1 50 50 msg="Time up!"
Would end the level within 5 secs.

(for more info, use F1 to get to Airstrike console and type "trigger".)


Note that the level end trigger can itself be triggered by another trigger
just by adding it a few keywords:
	trigger level-done timer 1 50 50 msg="Time up!" tag=timertrigger active=0
	trigger timertrigger spritekill bird 5


What I'm not sure about, is whether it's good idea to mix levels which
have a goal (e.g. kill a certain thing), and ones which are just about
deathmatch.

There can already be triggers for switching a level when any of
the players dies:
	generator player biplane 100 500 3 objtag=p1plane
	trigger level-done tagkill p1plane msg="Gotcha, player 1"
	generator player biplane 700 500 3 objtag=p2plane
	trigger level-done tagkill p2plane
	trigger level-done tagkill p1plane msg="Gotcha, player 2"
(Except that I haven't yet added the msg keyword)


Feel free to experiment and report bugs on it. :-)


	- Eero



More information about the airstrike mailing list