shieldsdown event?

Post ideas & suggestions you have pertaining to the game here.
Post Reply
F50
Fleet Officer
Fleet Officer
Posts: 1004
Joined: Sat Mar 11, 2006 5:25 pm

I am trying to make a mission that causes something to be triggered when the playership brings down the shields or damages an obj, is there any event tag that will do that for me?
User avatar
Periculi
Fleet Officer
Fleet Officer
Posts: 1282
Joined: Sat Oct 13, 2007 7:48 pm
Location: Necroposting in a forum near you

hmm... I know there is an event tag for shields down, but it is likely limited to the playership shields. Not sure that the event would trigger for NPC ships.

There is onObjAttackedByPlayer, which the Antartica uses and I posted a little example on how to use that (it's a bit tricky!) over at xelerus.

OnObjReconned might be of some limited use.


Ships are the only object with shields, but stations have the greater selection of events.

You could simulate shields for a station, and make specialized weapons to take out the station shielding. This could all be done from script so you could build in some controls.

Then you just need some kind of target script- when the player uses the scripted weapon, the actions you desire could result.

Maybe in a few days we will have other options with .99.
Bobby
Militia Captain
Militia Captain
Posts: 675
Joined: Wed Jul 25, 2007 7:39 pm

i think i recall making a wingman that calls the player for help when it's shields go down, try the event <onShieldDown> i think, or something like that, it's been quite a while.
F50
Fleet Officer
Fleet Officer
Posts: 1004
Joined: Sat Mar 11, 2006 5:25 pm

Can <onObjAttackedByPlayer> work when placed on a station for a ship registered for events?
User avatar
Periculi
Fleet Officer
Fleet Officer
Posts: 1282
Joined: Sat Oct 13, 2007 7:48 pm
Location: Necroposting in a forum near you

OnObjAttackedByPlayer seems to have some special case rules.

The CSC uses a blank station, which seems to be part of the requirement.

You can't use it just on a station, you can't use it just on a ship. You have to use it on a ship that is 'attached' to a station like the CSC's are.

The object you use can act like a station or a ship.
F50
Fleet Officer
Fleet Officer
Posts: 1004
Joined: Sat Mar 11, 2006 5:25 pm

eeeeeewww!
User avatar
Periculi
Fleet Officer
Fleet Officer
Posts: 1282
Joined: Sat Oct 13, 2007 7:48 pm
Location: Necroposting in a forum near you

The thing is, I did figure it out. :P

It's a complex and sort of esoteric bit of set up to use for an event- but it does work.

I posted the sample code on xelerus.
F50
Fleet Officer
Fleet Officer
Posts: 1004
Joined: Sat Mar 11, 2006 5:25 pm

I managed to solve my problem by making a recurring timer event that checks the health of the ship's shield, if you keep its shields down long enough to be checked by the timer, then my event will be executed.

The only problem now is that the ship's KM500 missiles won't track me because I told the ship to gate and not to attack.
Bobby
Militia Captain
Militia Captain
Posts: 675
Joined: Wed Jul 25, 2007 7:39 pm

you could solve that problem by having the same recurring event fire missiles at the player as it is retreating.
User avatar
Periculi
Fleet Officer
Fleet Officer
Posts: 1282
Joined: Sat Oct 13, 2007 7:48 pm
Location: Necroposting in a forum near you

<OnAIUpdate> ?
F50
Fleet Officer
Fleet Officer
Posts: 1004
Joined: Sat Mar 11, 2006 5:25 pm

I would use that but then I would have to re-write the shield.
User avatar
Periculi
Fleet Officer
Fleet Officer
Posts: 1282
Joined: Sat Oct 13, 2007 7:48 pm
Location: Necroposting in a forum near you

weell... so? A shield is a very tiny bit of xml.
F50
Fleet Officer
Fleet Officer
Posts: 1004
Joined: Sat Mar 11, 2006 5:25 pm

Yes, but that means that I would lose some control (number of ticks per update) and furthermore have to make the shield on the ship unique (yurgh).

anyways the problem is solved much more elegantly now.
Post Reply