[SCR] MARS Fire Control (v5.25 - 16.02.13)

The place to discuss scripting and game modifications for X³: Terran Conflict and X³: Albion Prelude.

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

Post Reply
User avatar
DrBullwinkle
Posts: 5715
Joined: Sat, 17. Dec 11, 01:44
x3tc

Post by DrBullwinkle » Mon, 24. Nov 14, 10:10

Hotkeys are sort of a weak point in X3. Missing hotkeys is not a guarantee that the rest of the script is not installed.

Did you get the message, when loading the game, that MARS is installed? That should happen, once, when your installation is correct. After "installation" it takes 2 minutes and 1 save/reload of X3 for MARS to completely activate.

Other indicators that MARS is installed include:
  • An Artificial Life Plugin (ALP). In space, press Esc until you see the Option Menu in the lower left corner of the screen. Choose Gameplay, then Artificial Life Settings. Is MARS on the list?
  • Motion Analysis Relay System ware available for sale at most equipment docks.

Geckomeister
Posts: 37
Joined: Sun, 1. Jan 12, 16:05
x3tc

Post by Geckomeister » Mon, 24. Nov 14, 10:13

I just worked it out....I needed to add the MARS file from the XRM link to plugin manager. After that it comes up in the AI menu.
Cheers
Gecks


eben
Posts: 23
Joined: Thu, 18. Dec 03, 00:59
x4

Post by eben » Sun, 7. Dec 14, 19:12

Hello there,

I have a serious problem with MARS recently.

To clarify things beforehand let me state that I've been playing this game for years and using MARS for almost as long.

Also I'm using a heavily modifed game which may or may not have caused the problem.

Now to the issue itself:

I've been happily blasting away with my MARS upgraded ships for almost 9 days of game time. Then suddenly (after a particularly intense firefight as far as I can deduce) the MARS started malfunctioning.

The symptoms are as follows:

* The "attack shields" option in the MARS menu started to do nothing. So does the regular "attack shields" command in the combat menu. What happens is when I designate a target to take down the shields the turrets go silent. When I taget the hulls again they resume firing.

* Mars turrets started to disregard the limitations set in the t file (size and damage). I set some custom weapons not to fire on capitals but mars began to ignore this. Before hand it obeyed perfectly.

* Restart MARS scripts option decided not to work anymore.

* Whenever a MARS equipped ship is missing the necessery weapons to mount the ships issued COMMAND changes to Mars.defend or Mars.attack instead of whatever it was doing.

All other MARS features function perfectly fromwhat I can see.

Now to explain further:

This has happened twice during my last two games. The first time I managed to fix it only by reinstalling the whole game and the mods, scripts etc.

And after a time in my second game it happened again. I've tried restarting the game, reinstalling mars, disabling or unistalling likely conflicting mods and scripts to no avail. Whatever I do MARS is now half broken.

I have two possible causes in mind, on which I will elaborate.

First is (because of the conditions this problem manifested) I suspect the workaround for performance is somewhat permanently altering something and this somehow persists through new starts and new installations of MARS sript.

Second is, I'm completely wrong abaout how this problem started and a mod or another script is causing this. But I have checked every mod and script I use file by file and nothing seems to override mars scripts and mars is not changing any vanilla files. So this is not likely.
Unless: MARS is using some vanilla and/or third party libraries and these somehow get changed by the mods I use.

Another thing I maneged to glean using MARS test mod is this:

When I designate a target for "shield attack" MARS test report shows this:

"Attack Shields active for Target: ARRAY ( null, null, null, null, null, null, null, null, ... )"

I hope these can help you help me because I cannot fix this for the life of me!

PS: I did not list the mods and scripts I use because it used to work perfectly beforehand. But will do so if required. And thanks for this magnificent script.

User avatar
DrBullwinkle
Posts: 5715
Joined: Sat, 17. Dec 11, 01:44
x3tc

Post by DrBullwinkle » Sun, 7. Dec 14, 22:02

eben wrote: * Whenever a MARS equipped ship is missing the necessery weapons to mount the ships issued COMMAND changes to Mars.defend or Mars.attack instead of whatever it was doing.

This has happened twice during my last two games. The first time I managed to fix it only by reinstalling the whole game and the mods, scripts etc.

And after a time in my second game it happened again. I've tried restarting the game, reinstalling mars, disabling or unistalling likely conflicting mods and scripts to no avail. Whatever I do MARS is now half broken.

I suspect the workaround for performance is somewhat permanently altering something and this somehow persists through new starts and new installations of MARS sript.

"Attack Shields active for Target: ARRAY ( null, null, null, null, null, null, null, null, ... )"
It sounds as though some state variable is getting stuck and not being cleared properly.

Does reverting to a saved game from before the first occurrence of the problem fix it?

eben
Posts: 23
Joined: Thu, 18. Dec 03, 00:59
x4

Post by eben » Mon, 8. Dec 14, 00:20

DrBullwinkle wrote:
It sounds as though some state variable is getting stuck and not being cleared properly.

Does reverting to a saved game from before the first occurrence of the problem fix it?
My last save before it happened was almost a day prior so I never tried that. Buy considering it even persists after starting a new game I shouldn't think so.

User avatar
DrBullwinkle
Posts: 5715
Joined: Sat, 17. Dec 11, 01:44
x3tc

Post by DrBullwinkle » Mon, 8. Dec 14, 00:56

Variables are stored in the saved game.

If it is a variable that becomes messed up, then reverting to a previous save should fix it.

If the problem persists in a new game, then it is in your game files. Most likely suspect would be something wrong in a language file that you edited. MARS is quite mature and I have never heard of a conflict with another (released) script. (although it is not impossible).

The game can be picky about xml syntax. A small error can cause the entire file to not be read. Visual Studio (including the free version) allows you to View Errors which will show any xml syntax errors in your language files.

Given the amount of installing and uninstalling that you describe, it is entirely possible that you had *both* problems at some point in the process. So try your previous save, and check the file(s) that you edited for syntax errors. Then proceed from there.

eben
Posts: 23
Joined: Thu, 18. Dec 03, 00:59
x4

Post by eben » Mon, 8. Dec 14, 12:16

DrBullwinkle wrote:Variables are stored in the saved game.

If the problem persists in a new game, then it is in your game files. Most likely suspect would be something wrong in a language file that you edited. MARS is quite mature and I have never heard of a conflict with another (released) script. (although it is not impossible).

The game can be picky about xml syntax. A small error can cause the entire file to not be read. Visual Studio (including the free version) allows you to View Errors which will show any xml syntax errors in your language files.
The real interesting thing is once the problem occurs, it will persist with a new start and reinstall of MARS. Meaning there are no edited t files. Also bear in mind that the script worked perfectly with edited files until the problem started. Besides what I did was add 3 custom lasers and MARS continues to recognize and use them after the problem started. The only problem with the custom lasers is; it does not adhere to target size restrictions. But just to be sure I'll check with visual studio even though I use notepad++ with xml plugin.

PS: I've checked the t file no syntax errors as I suspected.

redagent
Posts: 41
Joined: Fri, 20. Feb 15, 05:29

Post by redagent » Wed, 25. Feb 15, 03:51

Dear Moders, I need your help!
Finally I decided to test MARS, and after installing it found a little annoying issue.
I use in my game enlarged fonts and due to this I cannot see the options in MARS Configuration menu. I see only "..." instead of "on/auto/off" options.
Where and how I can change the size of this window to expand it, if it possible without hardcoding? I am far from from it. Very far.
Yes, I can easy to change fonts back to original, but those ones were pure torture for my eyes (Was the BDSM invented in Germany?)
I play X3:AP 3.1.

---------
Also I wanted to confirm the game crashes(freezes), while using MARS in particular situations. Now I think it is the issiue mentioned at this post
http://forum.egosoft.com/viewtopic.php? ... 06#4007806
connected to "Bounce" script from Litcube. But I am not shure, because I use a lot of other mods. though they were properly worked together for a long long time. And a few mods along MARS were installed recently - Sector Takover (STOv1.57), BounceV1.7 and Anarkis Defence System (ADS 265).

So the freez-issues only happened in sectors with Xenon ships - Xenon 598 and neighbor ZAyart's Dominion. And I fought in the same places with active mars turrets earlier without freezes. But I've made two things right before it happend (and continued to happen after same time after each reload):
- Installed Sattelite pattern with goblins using MARS Hotkey in Z.Dominion.
- activated mars turrets on a four M7-Agamemnons equipped with drones MK-2 and gathered in one wing assisting me in the battle. Also I had my carrier Xenon-J with 50 fighters operated by ADS. There was not so much ships in the space when freez happened - most of the fighers were docked on my carrier. And there was about 20-30 Xenon ships. when I turned off MARS turrets on all my four AGamemnons - all became ok. Finished that battle - kill all xenon in 598 and flew back to Z.Dominion.
After few minutes xenonn appears and drone started from my ship - game have freezed. - reload, jump to Z.dominion - freez again. Reload game, stop MARS On my ship - jump - fly few minutes in Z.Dominion - Freeez.
I tryed to stay in 598, jumped in other sectors - no changes - after every reload I got freez in few minutes.
So I load previous save and continued to play. Still then I have played about 6 hours (ingame time) and didn't use MARS turrets on my nonplayer ships and didn't start SAT-pattern. All stable. Bounce was enabled all this time
I just knew about issue with Bounce and going to repeat all the same without bounce. But I have dicided to write here first and maybe get some valuable information about all this stuff.

P.S. Sorry for my grammar - english is not my first language... niether the second.

User avatar
DrBullwinkle
Posts: 5715
Joined: Sat, 17. Dec 11, 01:44
x3tc

Post by DrBullwinkle » Wed, 25. Feb 15, 04:09

"Hard-coding" usually refers to compiled code. That requires resources to which most modders do not have access.

The menus are in scripts, which you can modify with the in-game Script Editor or X-Studio Script Editor.

If you are playing AP, then you could try changing the "open custom menu" lines to "open custom info menu". Info menus are the wide menus that you see in AP.

Freezes are usually caused by a bad loop in a script. Typically they are true bugs.

Stutters, which are momentary freezes, can have a variety of causes -- most of them performance-related. They may be unintentional, but may or may not be true bugs.

MARS is cpu-intensive, so stutters may be unavoidable during large battles, especially if you have MARS running on many ships.

Personally, I don't know of any freezes related to MARS. But I certainly do not know everything. :)

redagent
Posts: 41
Joined: Fri, 20. Feb 15, 05:29

Post by redagent » Wed, 25. Feb 15, 15:28

DrBullwinkle wrote:"Hard-coding" usually refers to compiled code. That requires resources to which most modders do not have access.

The menus are in scripts, which you can modify with the in-game Script Editor or X-Studio Script Editor.

If you are playing AP, then you could try changing the "open custom menu" lines to "open custom info menu". Info menus are the wide menus that you see in AP.
Thanks for clue, DrBullwinkle! It helped and menus have changed to suitable shape!

But I had to spent more than 1 hour to realize how to make it. Even this actions so simple to you was a "hard-coding" for me )))
I am goblin level one in the World of Scripts. And last code I wrote was a simple shooter on Sinclair BASIC for ZX-Spectrum in 1993.
So far I did all changes in scripts with text editor (AKelpad) and all was ok and worked properly after edit.

I could not find the strings "open custom menu" with text search in mars/scripts folder.
Then I made some investigation about X3:scripting and decided to try X-Studio. But It was a first time I use something more complicated than AkelPad. Spent some time for education... and found the desicion.

Well for those who want to do it but have the same level in scripting I giving this description which helps to spare your time:
Run X-Studio
Open script file from mars script folder plugin.gz.mars.config.xml
(I've found only one file with description "menu" in this folder)
In this file find string "open custom menu":
$Menu.Return = open custom menu: title=$Dummy1 description=$Dummy2 option array=$Menu.Arr
and change it to
$Menu.Return = open custom info menu: title=$Dummy1 description=$Dummy2 option array=$Menu.Arr maxoptions=null
Add text "info" and " maxoptions=null"
save. rewrite this file in game folder.

Now, MARS menu has become even wider, than you need. THat changes had affected on to both windows - ship menu and configuration menu. Covering half of screen space. But it is not a big deal - I am using hotkeys in combat.
Last edited by redagent on Wed, 25. Feb 15, 15:46, edited 2 times in total.

redagent
Posts: 41
Joined: Fri, 20. Feb 15, 05:29

Post by redagent » Wed, 25. Feb 15, 15:35

Deleted a stupid question from the lazy player, who do not like to read all those spreadsheets of manuals...
Last edited by redagent on Mon, 2. Mar 15, 11:24, edited 1 time in total.

redagent
Posts: 41
Joined: Fri, 20. Feb 15, 05:29

Post by redagent » Mon, 2. Mar 15, 04:35

redagent wrote:Also I wanted to confirm the game crashes(freezes), while using MARS in particular situations. Now I think it is the issiue mentioned at this post
http://forum.egosoft.com/viewtopic.php? ... 06#4007806
connected to "Bounce" script from Litcube. But I am not shure, because I use a lot of other mods. though they were properly worked together for a long long time. And a few mods along MARS were installed recently - Sector Takover (STOv1.57), BounceV1.7 and Anarkis Defence System (ADS 265).
At last I have caught the exact reason of the game crashes.
Bounce it is - with MARS... or MARS it is - with Bounce - you decide.
It happens only if I start MARS in the turrets of my owned ship(s) only in sector and Bounce enabled. not the ship I fly , but any of my AI-controlled ship.

EDIT. I've made few more tests. It doesn't matter how many ships are in sector - game crashes even if there is two of my ships and a few xenon ships.
I had only two ships in sector - my AI Tokyo without any ships in hangars. My own Agamemnon. 1 Xenon attacking me. And 3 or 4 Xenon M3 far away. Sextor Xenon 472. There is Xenon Shpyard and Xenon Station as well.

The only circumstances are:
Bounce 1.7 - enabled
Tokyo (AI) - MARS 5.25 - enabled (offence) in turrets - drones launched from this ship.
Agamemnon (own) - MARS 5.25 - disabled and MY own ship drones also launched by pressing hotkey (launch goblin at target).

The crush happens only if MARS drones were launched from both of my ships (own and AI) simulatenously. Launching them only from AI Ship(s) or only from my own do not causes crushes with Bounce enabled.
Apologize for Grammar! English is not my first language.
Played X2 for months. Played X3 for years. Played XR for one week. Now playing X3...

cpt1silencer
Posts: 1
Joined: Mon, 16. Mar 15, 11:54

turrets

Post by cpt1silencer » Mon, 16. Mar 15, 11:59

for some reason MARS isnt working correctly on my new ship, I have 16 starburst shockwave cannons and 12 spots to put them in, 8 main ones and 4 turrets, but mars keeps unequiping all but 1 of the 8 and uses 1 on each of the 2 turret areas, when i manualy equip them MARS takes them off again.

whats going on here? do i have to reload or something. 744 752 756 are the numbers it taged to my ship name.

User avatar
X2-Illuminatus
Moderator (Deutsch)
Moderator (Deutsch)
Posts: 24950
Joined: Sun, 2. Apr 06, 16:38
x4

Post by X2-Illuminatus » Mon, 16. Mar 15, 18:26

From the MARS FAQ:
Gazz wrote:Q: Why does MARS only load 1 laser into a turret when there could be 8?

A: For not doing anything, one laser is sufficient.
Nun verfügbar! X3: Farnham's Legacy - Ein neues Kapitel für einen alten Favoriten

Die komplette X-Roman-Reihe jetzt als Kindle E-Books! (Farnhams Legende, Nopileos, X3: Yoshiko, X3: Hüter der Tore, X3: Wächter der Erde)

Neuauflage der fünf X-Romane als Taschenbuch

The official X-novels Farnham's Legend, Nopileos, X3: Yoshiko as Kindle e-books!

Aszot
Posts: 6
Joined: Fri, 13. Feb 15, 04:07
x4

Post by Aszot » Sun, 22. Mar 15, 01:50

Hello,
I have small problem with MARS. Iam using Albion Prelude and XRM. When i install MARS, game spawns many of mammoths everywhere, or didnt instal at all saying : "cannot find 7047 bla, bla, bla... game dectected as vanilla". I tried everything and nothing worked :/ Hope you guys will help me :)

Ps. I read manual, FAQ and similar problems and solutions. Nothing worked...

User avatar
X2-Illuminatus
Moderator (Deutsch)
Moderator (Deutsch)
Posts: 24950
Joined: Sun, 2. Apr 06, 16:38
x4

Post by X2-Illuminatus » Sun, 22. Mar 15, 11:16

Have you also read the installation intructions for MARS posted in the XRM topic?
paulwheeler wrote:MARS: MARS is compatible - Do not use the full repackaged version - either use the manual install and do not install the MARS drones cat/dat - just the scripts. The drones are already merged into the XRM and installing them will break the XRM, or use Bullwinkle's repackaged version for mods that include TShips. You will also need the custom MARS data file above. Simply copy this into your "t" folder ("addon\t" for AP)
Nun verfügbar! X3: Farnham's Legacy - Ein neues Kapitel für einen alten Favoriten

Die komplette X-Roman-Reihe jetzt als Kindle E-Books! (Farnhams Legende, Nopileos, X3: Yoshiko, X3: Hüter der Tore, X3: Wächter der Erde)

Neuauflage der fünf X-Romane als Taschenbuch

The official X-novels Farnham's Legend, Nopileos, X3: Yoshiko as Kindle e-books!

Aszot
Posts: 6
Joined: Fri, 13. Feb 15, 04:07
x4

Post by Aszot » Sun, 22. Mar 15, 11:30

Yes. I used this version for mods. This with only 2 folders: t and scripts. I found one thing: I used polish version of game, but when i change langue to english everything works perfectly.

GlassDeviant
Posts: 291
Joined: Sun, 4. Nov 12, 12:06
x3tc

Post by GlassDeviant » Sun, 22. Mar 15, 15:55

I am guessing I should avoid using MARS with anything like Smart Turrets, or Weapons Select Extension, which also affect(s) weapons systems? Or rather, avoid using them with MARS.

Edit: I came up with a list of mods (subset of the mods I am trying to use) which I think might duplicate parts of MARS, conflict with parts of MARS, or otherwise be unnecessary/undesurable to use with MARS:

Smart Turrets v4.7.2
Missile Safety
Weapon Select Extension v2.02
Auto Aim (for cursor follow mode)
Drone Carrier Software v2.07a
Turret Toggle BW Missiles Only v4

Can anyone confirm or deny any of these [s]educated guesses[/s] almost completely unsupported speculations?
bibo ergo sum

dholmstr
Posts: 401
Joined: Tue, 12. Apr 11, 19:41

Post by dholmstr » Wed, 9. Mar 16, 10:23

Such an old thread, hope I don't get banned for this.

I have the MARS installed (yes I still play X3 even with Rebirth out and all) and I'm loving it. But right now it shoots PPC's and other big guns as volleys, not as an "continues" stream. Like holding the trigger just on. Can I change that somehow somewhere? Smaller guns shoot as much as they can but I would like the big guns to do the same. This as no other value but it looks sexier and cooler!

Post Reply

Return to “X³: Terran Conflict / Albion Prelude - Scripts and Modding”