EnglishGermanFrenchRussianPolishItalianSpanish
Log inRegister
 
[SCR] Missile Safety (v1.12)
Post new topic Reply to topic Goto page 1, 2, 3, 4, 5  Next
View previous topic :: View next topic
Author Message
Gazz





Joined: 13 Jan 2006
Posts: 12407 on topic
Location: Bavaria
Thank you for registering your game
modified
PostPosted: Sat, 7. Mar 09, 14:25    Post subject: [SCR] Missile Safety (v1.12) Reply with quote Print

English / Deutsch

Missile Safety

  • This script is compatible with TC and AP.

  • Especially when flying a fighter it is not uncommon that missiles that you launch are immediately destroyed by enemy fire - or by your own cockpit guns / turrets.

  • This script provides a missile safety so the warheads are armed after the missile is at least 200m clear of your ship.

    Note that this is not foolproof. A lucky shot can still detonate a missile even if the warhead isn't armed.
    (Firing at warheads is neither safe nor recommended by the manufacturer)

  • This only affects missiles that
    • are launched by the playership
    • have a target
    • are of the type that is selected as current missile in the cockpit

  • The missiles do not have to be launched manually as long as they meet the aforementioned conditions and are launched at the current cockpit target.
    Scripts like Missile Barrage or MEDUSA could make use of this.

  • This ignores missiles fired by huge ships (M1, M7M...) because these simply do not have the problem of missiles instantly being destroyed on launch.
    It is a fighter issue.
    And I wanted to exclude massive missile barrages. =)

  • This is an AL plugin. It can be turned on/off under Gameplay / AL Plugins.

  • In X3:AP, this script can be enabled for the AI as well.
    Copy the contents of the scripts\X3AP_Missile_Safety_AI folder into \scripts\.
    In the long run this is only going to work with Steam in Offline mode (or with updates disabled for AP) because it is necessary to overwrite vanilla files... which Steam would "fix" again.

  • For scripters:
    To use Missile Safety for any AI ship, insert one script call before the actual launch instruction.

    Code:
    020 skip if not get global variable: name='GZ.MSL.SAFETY'

    021    @ = [THIS] -> call script 'al.plugin.gz.missile.safety' :  plugin ID=null  plugin event='launch'  Missile launched=$Missile  Target Old=$Target

    022   = [THIS] -> fire missile $Missile on $Target


How To Use AL Plugins

Download: ZIP


Installation
Copy the contents of the zip into the X3_TC folder
or in the case of X3:AP, into ... \Steam\SteamApps\common\x3 terran conflict\addon


Deinstallation
  • Turn off the AL plugin under Gameplay / AL Plugins.
  • Save.
  • Delete TC\scripts\al.plugin.gz.missile.safety.xml

Resources used:
Task ID 47050 and 57050 on the playership.


_________________
My complete script download page. . . . . . Xai-Corp MSCI List is scripter's friend. I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.


Last edited by Gazz on Tue, 27. Dec 11, 05:44; edited 14 times in total
Back to top
View user's profile Send private message Visit poster's website
Gazz





Joined: 13 Jan 2006
Posts: 12407 on topic
Location: Bavaria
Thank you for registering your game
PostPosted: Sat, 7. Mar 09, 14:25    Post subject: Reply with quote Print

* * reserved * *

Back to top
View user's profile Send private message Visit poster's website
argon_emperor



MEDAL

Joined: 12 Dec 2005
Posts: 1047 on topic
Location: Townsville, Australia
Thank you for registering your game
PostPosted: Sat, 7. Mar 09, 14:57    Post subject: Reply with quote Print

Sounds good, will give it a spin tonight.

Back to top
View user's profile Send private message MSN Messenger
Lancefighter





Joined: 19 Dec 2004
Posts: 2936 on topic

Thank you for registering your game
PostPosted: Sat, 7. Mar 09, 23:05    Post subject: Reply with quote Print

a question from a technical standpoint:

its an AL plugin...
I was under the impression those are only run every 1 minute at most, yet i assume it works on missiles as soon as they launch

So erm how does it actually work?

I tried to take a look at the file but it makes no sense in notepad2 or the ms xml editor...
(whats a good out of game editor type thing for x3tc files?)


_________________
in the market for a new sig, willing to pay 1 billion credits for a proper sig...
Back to top
View user's profile Send private message
Gazz





Joined: 13 Jan 2006
Posts: 12407 on topic
Location: Bavaria
Thank you for registering your game
PostPosted: Sun, 8. Mar 09, 01:00    Post subject: Reply with quote Print

Lancefighter wrote:
its an AL plugin...
I was under the impression those are only run every 1 minute at most, yet i assume it works on missiles as soon as they launch

So erm how does it actually work?

Hahaha!
Since AL plugins already have a library structure this single script runs in 3 different ways in 3 different places/tasks.
Up to 2 of them run on the playership...


_________________
My complete script download page. . . . . . Xai-Corp MSCI List is scripter's friend. I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.
Back to top
View user's profile Send private message Visit poster's website
Lancefighter





Joined: 19 Dec 2004
Posts: 2936 on topic

Thank you for registering your game
PostPosted: Sun, 8. Mar 09, 01:03    Post subject: Reply with quote Print

erm.

Ill take your word that it will work then Confused


_________________
in the market for a new sig, willing to pay 1 billion credits for a proper sig...
Back to top
View user's profile Send private message
LV
Sith Lord




Joined: 06 Nov 2002
Posts: 6359 on topic
Location: The Dark Side
Thank you for registering your game
PostPosted: Sun, 8. Mar 09, 01:18    Post subject: Reply with quote Print

Lancefighter wrote:
(whats a good out of game editor type thing for x3tc files?)


to view the best thing is firefox or ie as long as the script is in the same folder as the x2script.xsl found in your scripts folder ( i have a temp folder with that file in to view scripts while keeping them away from the game directory)


to edit, the script editor, unless i've missed something seriously major there is no stable standalone editor, alterations via the script editor are the only way i know of


_________________
LV's TC Scripts
Readme's For All My Scripts


I felt a great disturbance in the forum, Like millions of voices cried out in terror, then were silenced

si tacuisses, philosophus mansisses
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
Gazz





Joined: 13 Jan 2006
Posts: 12407 on topic
Location: Bavaria
Thank you for registering your game
PostPosted: Sun, 8. Mar 09, 01:33    Post subject: Reply with quote Print

Just follow the tasks...
At the Work: part it starts spawning into different places and it eventually runs on 3 different timers simultaneously.

Sure, I could have split it into 3 scripts but since AL plugins are already perfectly suited to act as their own library I just wrapped it all in one.

Since it's a very small project (1-2 pages of script per task) there was no danger of losing track of things. In fact I wrote it, turned it on, and it worked...
It's really very simple once you acquire the proper multiple schizophrenia.


_________________
My complete script download page. . . . . . Xai-Corp MSCI List is scripter's friend. I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.
Back to top
View user's profile Send private message Visit poster's website
pelador





Joined: 06 Nov 2002
Posts: 1230 on topic
Location: UK
Thank you for registering your game
PostPosted: Sun, 8. Mar 09, 01:40    Post subject: Reply with quote Print

Exscriptor - works well as an external editor (so far I have found it to be relatively stable)


_________________
X3TC:V2.1M

Dedicated Assistant Drones (DAD); Pirate Fence; Player Workshops; Convert Passenger to Marine
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Fightin 501st





Joined: 28 Feb 2009

Location: 41.38.04.67 N; 73.00.11.61 W

PostPosted: Sun, 8. Mar 09, 11:34    Post subject: Reply with quote Print

[angelic choir]alleuiaaaaaaaaa[/angelic choir]


_________________
A dog isn't a mans best friend;

A gun is.
Back to top
View user's profile Send private message
INSTG8R





Joined: 30 Jul 2006
Posts: 163 on topic

Thank you for registering your game
PostPosted: Sun, 8. Mar 09, 18:32    Post subject: Reply with quote Print

Fightin 501st wrote:
[angelic choir]alleuiaaaaaaaaa[/angelic choir]


Amen to that!

Thanks so much Gazz for making this Script!!! Very Happy Cool

Back to top
View user's profile Send private message
adecoy





Joined: 24 Jan 2007
Posts: 203 on topic

Thank you for registering your game
PostPosted: Mon, 27. Apr 09, 20:18    Post subject: Reply with quote Print

thanks for this! no longer will i be afraid to use missiles! Thumb up


_________________
Back to top
View user's profile Send private message
Predator02





Joined: 28 Jul 2007
Posts: 483 on topic

Thank you for registering your game
PostPosted: Mon, 27. Apr 09, 23:39    Post subject: Reply with quote Print

This is a wonderful script, especially with heavy explosive torpedoes.

Back to top
View user's profile Send private message AIM Address
Gazz





Joined: 13 Jan 2006
Posts: 12407 on topic
Location: Bavaria
Thank you for registering your game
PostPosted: Sat, 16. May 09, 17:38    Post subject: Reply with quote Print

Version 1.05 released.

Prepared script to be used by AI ships.

They will not actually make use of it until the script call is tied into the fight scripts.


_________________
My complete script download page. . . . . . Xai-Corp MSCI List is scripter's friend. I AM THE LAW!
There is no sense crying over every mistake. You just keep on trying till you run out of cake.
Back to top
View user's profile Send private message Visit poster's website
aka1nas





Joined: 07 Jul 2005
Posts: 1381 on topic

Thank you for registering your game
PostPosted: Mon, 18. May 09, 00:28    Post subject: Reply with quote Print

Gazz wrote:
Version 1.05 released.

Prepared script to be used by AI ships.

They will not actually make use of it until the script call is tied into the fight scripts.


Woohooo! Can't wait until it's ready! Is that going to be a part of your OOS redux?

Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic Reply to topic Goto page 1, 2, 3, 4, 5  Next
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum
Control Panel
Login Data
The time now is Fri, 20. Oct 17, 14:31

All times are GMT + 2 Hours


Board Security

Copyright © EGOSOFT 1989-2017
Powered by phpBB © 2001, 2005 phpBB Group
Template created by Avatar & BurnIt!
Debug: page generation = 0.44902 seconds, sql queries = 29