[SCR] Turret On/Off Hotkey

The place to discuss scripting and game modifications for X³: Reunion.

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

Post Reply
User avatar
Gazz
Posts: 12423
Joined: Fri, 13. Jan 06, 17:39

[SCR] Turret On/Off Hotkey

Post by Gazz » Sat, 28. Jun 08, 14:27

(Das entsprechende deutsche Topic ist hier.)
  • This script installs 1 hotkey.
  • Pressing the hotkey pauses all turrets on your ship for 5 minutes or until you change sectors.
    Whatever comes first.
  • Pressing the hotkey again unlocks your turrets.
  • Starting a new turret script on one turret unlocks that particular turret.
  • If you have one of your ships targeted and this ship does have turrets, the pause/continue is applied to that ship instead of yours.
  • Some of you may now say that this already exists here.
    The difference is that this script here works with all current and future turret scripts without any changes.
    It also doesn't disable the turrets indefinitely. I sometimes forgot turning them back on and didn't even notice since I had switched to another ship.
Image (ZIP + SPK)
My complete script download page. . . . . . I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.

Lancefighter
Posts: 2936
Joined: Sun, 19. Dec 04, 03:41

Post by Lancefighter » Sat, 28. Jun 08, 18:48

Strange...

You have this line:

$Target -> interrupt task $Nr.of.turrets with script "plugin.gz.turret.onoff.turret" and prio 5 : arg1= null arg2= null arg3= null arg4= null


does the 'get number of turrets' command also get them in such a way that you can command them like you are?

And my general overview of the script is that it will put a task in front of the current turret script, and wait until the timer is up, then get rid of said task. Is this correct?

I also note you get the number of turrets multiple times... is that needed?
in the market for a new sig, willing to pay 1 billion credits for a proper sig...

Post Reply

Return to “X³: Reunion - Scripts and Modding”