[airstrike] Triggers and level ending
ulfek at ifm.liu.se
Mon Jul 4 06:34:38 EDT 2005
Hi, sorry for my general slowness..
Eero Tamminen wrote:
> I've added an initial trigger object implementation and a few trigger types
> to Airstrike SVN.
> There are still a couple of problems:
> - How I call (message) an object to which I have only an ID (or tag)?
Use obj_lock(id,obj_type) to get a pointer to the object, send the
message and unlock.
> - I would like to schedule trigger object events, but currently only sprites
> have a convenience function for this. Would it be possible to move
> schedule to core, and have a convenience function for message sending
You can do it already, with schedule(). Of course we can add a function
that just passes the message along to the target. I will have a look at it.
> - I haven't tested all the trigger types I coded yet,
> I will do that next week
> - Proximity trigger is still missing and will/would be very nice. I'll
> look into this once the other stuff is tested/ready
I started to create functions for this some time ago, I will take it up
again. Basically we need a little library of different shaped masks that
can be used for testing proximity (disc and cone shapes come to mind).
This is also needed to write an ai that can avoid hitting things.
> - Game should show in the window whether level ended succesfully.
> I guess level should restart if it failed... :-)
> - Rest of the levels should have level-done/fail triggers too
> - I was also thinking that plane should suicide if user tries to bomb, but
> there's neither more bombs nor fuel, would that be acceptable?
I think Erik's self-destruct button would be nice (or dying after some
> I though to add level-fail condition to planes dying too many times to
> each level. Other alternative would be to just have a "Restart level"
> key. Opinions?
Yes, I think that it should end automatically after too many deaths.
More information about the airstrike