Defence station (scrip) posibility

The place to discuss scripting and game modifications for X4: Foundations.

Moderators: Scripting / Modding Moderators, Moderators for English X Forum

solarie99
Posts: 152
Joined: Fri, 21. Dec 18, 00:55
x4

Defence station (scrip) posibility

Post by solarie99 »

Hello there !

I was sitting as watching my defence station killing xenons and keeping an ally space safe, and it hit me why dont the station get to collect the bounty of ships itdestroys? :gruebel: :gruebel:
it would open up an interesting game mechanic.
That will allow you to be a defence mercenary to sector spaces, and not needing to have billions of ships all over the place. it would be then directly benefical for you to build more station and help the other factions out.

I have no idea if this is posible at all but as i see it, it is a thing that should be in the main game tbh. :roll: :D

The end of the idea.
Have a nice day all. :)
User avatar
euclid
Moderator (Script&Mod)
Moderator (Script&Mod)
Posts: 13486
Joined: Sun, 15. Feb 04, 20:12
x4

Re: Defence station (scrip) posibility

Post by euclid »

I think it's doable but needs some work. The rewards are handled in notifications.xml and are triggered via event_player_killed_object which applies only for the ship the player is flying on. You'd need a script that triggers via event_object_destroyed with a check whether the (param = ) killer is player owned, and then call the cue in notifications.xml that actually handles possible rewards. i.e. <signal_cue_instantly cue ="md.Notifications.AttackResponse" param="event.object" />. However, this cue demands other parameters and atm I have no idea how to provide them nor what the consequences are if you do not provide them.

Cheers Euclid
"In any special doctrine of nature there can be only as much proper science as there is mathematics therein.”
- Immanuel Kant (1724-1804), Metaphysical Foundations of the Science of Nature, 4:470, 1786

Return to “X4: Foundations - Scripts and Modding”