[SCRIPT] Apollyon Arms: Laser Weapon Switcher (LWS)

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

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

Rate this script

Excellent
7
70%
Good
0
No votes
Okay
0
No votes
Poor
0
No votes
Terrible
0
No votes
Not interested
3
30%
 
Total votes: 10

(----____JEFF____----)
Posts: 269
Joined: Sat, 20. May 06, 14:55
x3tc

Post by (----____JEFF____----) »

Since this one of my first attempts at scripting (in X3) I really wanted to do this my self, hence the no feedback from me.

The most important part I changed is the library, which includes the vanilla and XTM weapons. Except the ones I mentioned before.

In my game I also removed the message it sends when you load your game (about it being installed properly). And I changed the cmd slot as well. So I also modified the setup file, I believe it was?

I might want to leave the message in for the release version, that way you at least know it's properly installed.
1) weapon list in the original library was placed in a special order. Changing the order - I'm sure you're aware now - affects the system.
Yup, I'm aware of that ;)
2) I toyed with a few systems for the weapons library and found that the "gosub" branches was the most efficient for what I had in mind. I took into account the probability of mass amounts of LWS systems being run simulataneously, simplicity of use, effectiveness of the system, and streamlining the code as much as possible. If you check how the script actually runs you'll find it runs much shorter than it looks (about 1/10th of the actual script length). This system is actually the 3rd system I developed for weapons switching and it allowed every ship in the game to run the LWS (non-player AI included - over 1000 ships total in my test runs) without a performance problem. Of course if you find an even more efficent system that's great.
I'm going to assume you did some good testing with it ;) maybe if some of the scripting gods have some ideas we'll probably hear something from them ;)
Erm... that seems like a problem to me. It may just be a text problem though - did you change the text for ship_46 to "LWS"? Before doing that though I suggest to check if the Otas is part of XTM or just some left over relic from something else.
Let me explain it a bit clearer ;) When you click enter on one of the two slots you get the list of commands, right? There it does show as "LWS", but when you select it you see Otas ECM in that slot. I hope you understand what I mean, from your reaction I had the idea you didn't entirely.

Well I'm sure Otas ECM is part of XTM, there is a company called Otas in XTM and it has a special hull regenerating system in some of it's ships. I believe that ECM is that system, (or one of the other systems they have).
If you've read the readme for the LWS I believe I mentioned something about the Apollyon Ballistic Computer (ABC). Here's what I propose -

The LWS was intended as a basic system for automatic weapons management, which is what it came as default on the FCS. The ABC was intended as a higher level system upgrade that included shield/hull calculations, higher level power control and ballistics (i.e. which weapon to use vs. target's shield strength vs. power drain vs. target speed to weapon speed ratio). Since I don't have the time right now... and since you're already working on something including shield calculations why not expand the LWS into the ABC?
Well I do remember the ABC, but now I can't find anything about it in the readme. I would like to refresh my knowledge about it, because I forgot it mostly.
You mean like combining LWS and the ABC in one package? That's fine with me.

I originally liked this script because it is very useful and it's packed with the FCS (a default on all my ships), so maybe we can also have a "light" version with less features?

PS: changes in list form:
- library update
- include vanilla and XTM weapons, except area effect and CIG)
- Alpha and Beta and Gamma preferences (sometimes Alpha is better then Beta)

- changed cmd slot (compatibility not confirmed)
- removed the installation message
Laureati
Posts: 140
Joined: Sat, 20. May 06, 11:42
x3tc

Post by Laureati »

(----____JEFF____----) wrote:Let me explain it a bit clearer ;) When you click enter on one of the two slots you get the list of commands, right? There it does show as "LWS", but when you select it you see Otas ECM in that slot. I hope you understand what I mean, from your reaction I had the idea you didn't entirely.

Well I'm sure Otas ECM is part of XTM, there is a company called Otas in XTM and it has a special hull regenerating system in some of it's ships. I believe that ECM is that system, (or one of the other systems they have).
Okay it's fairly clear that Ship_46 is then not a compatible slot then. You'll probably find the Otas ECM along the way and wind up with problems if you install one.

This is why I'd really prefer a slot given from the XTM developers themselves as they'd know their system best.

HONESTLY, I WANT THE LWS TO BECOME XTM COMPATIBLE.

As I proposed earlier, for those who wish the LWS to be XTM compatible request for the XTM team to assign me a slot and I'll gladly release a compatible system - in which case Jeff, I think your library would be a welcome addition to the XTM version of the LWS.
(----____JEFF____----) wrote:Well I do remember the ABC, but now I can't find anything about it in the readme. I would like to refresh my knowledge about it, because I forgot it mostly.
You mean like combining LWS and the ABC in one package? That's fine with me.

I originally liked this script because it is very useful and it's packed with the FCS (a default on all my ships), so maybe we can also have a "light" version with less features?
Nice to hear that you viewed the script exactly the way I designed it to be used - a useful, simple addition to the X3 universe.

The LWS is the "light" version. The Apollyon Advanced Ballistic Computer would be the complex, advanced system. The ABC system (as of pre-scripting design) is aimed as a stand alone and expensive add-on. Weapons are selected on a multi-tier system.

This multi tiered system would then select the best weapon for the target in any given situation extending and improving the combat viability of the ship above and beyond what the LWS can deliver. It will be an expensive, non-standard add-on because of: -

1) it's "far more intelligent" weapon management

2) The amount of script calls this system would require would affect system performance if used in large numbers
(----____JEFF____----) wrote:PS: changes in list form:
- library update
- include vanilla and XTM weapons, except area effect and CIG)
- Alpha and Beta and Gamma preferences (sometimes Alpha is better then Beta)

- changed cmd slot (compatibility not confirmed)
- removed the installation message
Ah, I see... okay I'll be brutally honest here. You could make your own release, I can't stop you on that. But: -

a) Your system would be a modification of my system - which hopefully you'll give credit for. e.g. "Based on the Apollyon LWS by Laureati"

b) Erm... what's the difference between Alpha, Beta and Gamma? And what's the idea behind it?

c) What's the point of having 2 different scripts - under different names - that basically do the same thing (especially since both scripts are based on the same code i.e. the LWS protocal script)?

The library and setup scripts are a part of the system, but the bulk of the real work I did came in creating the actual protocal script, which obviously you aren't going to change.

That script looks simple but it was not an easy task to design. I don't mean to sound like I'm blowing my own horn, but let me put it to you this way - even with all the excellent scripters in this forum - aside from the FCS mk3 - there isn't single autonomous, forward laser, weapons management script like the LWS at all even though lots of mod users have specifically requested for one. (The FCS mk.3 is in a totally different class of functionality, design, and costing).

That's why I offered you a library update credit. I've very happy that someone has updated the library to their liking. The library system was designed to be simple, logical and easy to modify so that people could tweak it as they liked. And I'm always happy to have people contribute to the library to expand and improve it (that's also in the readme and the erm... "news story").

But honestly I'm not too keen on a "new" script coming out under another name that is basically running off the main protocal script I worked very hard to create.

Now I'm more than happy to work WITH you to get the LWS into a fully XTM compatible state and share equal credit with you. Moving ahead is always a good thing. However, I'm just not crazy about you making your own script off the totally original protocal that I worked very hard to create. :D
(----____JEFF____----)
Posts: 269
Joined: Sat, 20. May 06, 14:55
x3tc

Post by (----____JEFF____----) »

I'm not planning on releasing it on my own and I know I wouldn't be a happy man if someone stole my script I had worked many hours on.

And I also like to state that I could never have made this on my own, with my current knowledge of X3 script. It's just that I know some "flash actionscript" and a few other scripting languages, that I how scrips work and that I can understand something like the LWS library and (after a lot of research) how to change cmd slots.

Further more it would be a honor to work together with you on the LWS and maybe other scripts (like the ABC) ;)
b) Erm... what's the difference between Alpha, Beta and Gamma? And what's the idea behind it?
Well as we all know (I thought). Alpha fires faster than the other two (Beta and Gamma), this could be important for shooting down missiles or fighter drones, because "doing damage" is not important against those.
Also Alpha uses less energy, so it's more useful when your low on energy.
Another difference is that Alpha "bullets" are faster than Beta and Gamma, I find the difference between Alpha and Beta HEPT so big that I think of them as two whole different weapons. Alpha HEPT is still useful for allot of fighters, but Beta HEPT is more for M3 and heavier classes.

That's the basic idea.
c) What's the point of having 2 different scripts - under different names - that basically do the same thing (especially since both scripts are based on the same code i.e. the LWS protocol script)?

There is no point.
...there isn't single autonomous, forward laser, weapons management script...
Not to sound rude but there is one other, it's part of the TCS made by mrcann:
http://forum.egosoft.com/viewtopic.php?t=180084

And on a side note, maybe we can use the cmd slot he's using :P :twisted: as it's XTM compatible.
But I prefer the LWS, because of it's usability for scrtipters and users alike.

*Looking forward to your answer and hoping for cooperation*
Laureati
Posts: 140
Joined: Sat, 20. May 06, 11:42
x3tc

Post by Laureati »

I'm not planning on releasing it on my own and I know I wouldn't be a happy man if someone stole my script I had worked many hours on.
Thanks, that's good to know. However if you develop a better system, it'd be great to see. Then I don't have to rack my brain so hard over code. Haha. :D
Further more it would be a honor to work together with you on the LWS and maybe other scripts (like the ABC)
It'd be very happy to have others to work with. It'd be great having someone with experience with scripting languages as I don't. Got to say this about X3, the developers made it really modder friendly and this forum has been a great place to learn.
Alpha fires faster than the other two (Beta and Gamma),
Ah you meant weapon types. Well... The LWS already has anti-drone, anti-missile modes (oh, shoot that may be in the unreleased 1.5 - sorry everyone but work comes first) where the system switches to the fastest, lowest firepower weapon available (drone/missile must be targeted for the system to recognise it though, that's why it's recommended that the LWS be paired with the Apollyon Targeting Extensions).

Remember that the LWS is a "basic" free version - there's a reason for this which I shall not divulge at the moment. Regardless it's still very useful and shows what this system is capable of.
Not to sound rude but there is one other, it's part of the TCS made by mrcann
I'm aware of the several excellent TURRET scripts around. The LWS is the ONLY AUTONOMOUS, FORWARD LASER, system. The only thing close is Bunny's Weapon Switcher which uses an system of manual pre-sets. Different system altogether. - I did my homework :)
And on a side note, maybe we can use the cmd slot he's using as it's XTM compatible.
Hahaha. No, we wouldn't want to hamper our nice capital class ships would we? It's actually an excellent system to pair with the LWS since the LWS ignores turrets.
Looking forward to your answer and hoping for cooperation
Yes, definitely would love some help on this. I'm just too busy right now to do scripting and the huge amount of testing I do pending a release. I'm also a bit stuck on the OCS Apollo, but thankfully X-freak Cartman has offered to take the reigns on that for now.

Main things that need to be addressed will be an open slot for XTM. If you could find one, or just ask the XTM team for one that'd be great. Keep up the work you're doing and test out your system in various combat conditions. I suggest you create a ship spawn system so you can just call up various ships with different weapons loadouts at anytime to test it out.

I think we'd best keep the rest of this correspondance on PM - no point bombarding people here with unnecessary information - and spoilers... haha. :D

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