Page 1 of 2

[RELEASE] Combat Simulator OXP (1.77 only)

Posted: Sat Feb 16, 2013 3:07 pm
by cim
This OXP adds a combat simulator to some stations (generally the higher-tech ones, but also Lave...) where you can set up controlled battles against particular opponents. To start a fight, go to the interfaces screen (F4) and select "Combat Simulator". Then, select the ships, skill, and numbers of your opponent(s).

The fight will end if:
- you defeat all your opponents
- your ship would be destroyed
- the simulator buoy is destroyed
- you leave scanner range of the simulator buoy

You will not be able to use an escape pod or hyperspace during the simulation.

All damage taken, consumable items used, etc. during the fight will not be applied to your real ship. The ship you fly in the simulator will be your current ship in whatever state it is currently in.

There is no charge for using the simulator, but it is a popular service and there is often a queue. Expect to wait around ten minutes for your turn.

This OXP requires Ship Storage Helper OXP and will not run without it. Download Combat Simulator 1.0

(This replaces the old "Combat Arena" test OXP)

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Sat Feb 16, 2013 3:26 pm
by Cody
Nice... I just took a good slapping!

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Sun Feb 17, 2013 11:52 am
by Diziet Sma
Nice.. I was wondering what you had planned for the Combat Arena. 8)

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Sun Feb 17, 2013 12:07 pm
by GGShinobi
Wow cool! :o

Finally I can fight safely against my brutally pimped nightmare - stardestroyers :lol:

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Mon Feb 18, 2013 9:55 am
by Rorschachhamster
GGShinobi wrote:
Wow cool! :o

Finally I can fight safely against my brutally pimped nightmare - stardestroyers :lol:
Hey! did you get that OXP'ed? I'd really like to try them out... :twisted:

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Mon Feb 18, 2013 12:25 pm
by Lestradae
Just wanted to report that the Ship Storage Helper oxp still repeatably produces a memory overrun on my system, OS Windows 7 64bit, use the semi-stable 1.77 Oolite.

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Mon Feb 18, 2013 12:40 pm
by GGShinobi
Rorschachhamster wrote:
GGShinobi wrote:
Wow cool! :o

Finally I can fight safely against my brutally pimped nightmare - stardestroyers :lol:
Hey! did you get that OXP'ed? I'd really like to try them out... :twisted:
Yes, I did!!! :D And if you got at least 3 (better 4) military lasers installed you might even be able to stand a chance against one (if you are lucky and stay out of it's turret-range). The ship has incredible shields, and a high energy recharge rate. In addition to the myriad of turrets it already had, it now has 2 Military Lasers (front and aft), 2 Thargoid lazers (sides) and tons of missiles. As if it was not enough to make the ship extremely more powerful and even faster (but less manoeuvrable) - it's very fast now, and has much fuel so it uses the injectors often- the Star Destroyer will now be escorted by 4 interceptors - which will be TieFighters if you also have them installed (very nasty). :twisted:

You'll also need an ECM or a space station to hide behind, as it has many missiles and uses them without hesitation.

The modified version has a chance of 33% to spawn a timebomb-stardestroyer when it get's destroyed. The crew of the doomed stardestroyer will broadcast a desperate message when this happens, so you get a warning and have time to run! :wink: The timing problem was solved by doing it inside of the AI of the timebomb-stardestroyer.

The good thing: if you kill one and are lucky enough that its' reactor core doesn't breach (so that there is no big explosion) you will get the chance to scoop many many escape pods! :wink:

The only thing that still doesn't quite work as I want is that the "destroyed stardestroyer", by which the original stardestroyer gets replaced when it gets destroyed, has the same orientation... :roll: still have to find out how to do that.

Here is the excerpt of the stardestroyers' ship-script:

Code: Select all

this.shipDied = function(whom, why) {
  if (Math.random() > 0.77) { // chance for reactor breach: 33 %
    for (var doomedStarDestroyer in system.addShips("stardestroyer_reactor_breach", 1, this.ship.position, 0)) {
      // change orientation to that of the original ship
      doomedStarDestroyer.orientation = this.ship.orientation;
    }
  } 
}   
This: doomedStarDestroyer.orientation = this.ship.orientation; doesn't seem to work. Any clues, anyone? :roll:

Download the modified version from my box: Star Destroyer - Nightmare Version :twisted:

Note that the testscript "spawn.js" is activated, which causes a stardestroyer to spawn every time you launch from station. If you've had enough fun with it, disable the function by changing it to:

Code: Select all

//this.shipWillLaunchFromStation = function() 
//{ 
//    system.legacy_addSystemShips(this.role, this.count, 1.0); 
//    log("testscript.spawn", "Generated " + this.count + " " + this.role + " for testing purposes."); 
//} 
(Appending the "//" makes comments out of the lines.)

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Mon Feb 18, 2013 12:52 pm
by cim
GGShinobi wrote:

Code: Select all

for (var doomedStarDestroyer in system.addShips("stardestroyer_reactor_breach", 1, this.ship.position, 0)) {
      // change orientation to that of the original ship
      doomedStarDestroyer.orientation = this.ship.orientation;
    }
This: doomedStarDestroyer.orientation = this.ship.orientation; doesn't seem to work. Any clues, anyone? :roll:
for (var x in xs) { assigns the key, not the value, to x (which may surprise you, if you're used to other languages). So what you are then doing is 0.orientation = this.ship.orientation, which won't work. Instead, do

Code: Select all

var doomedStarDestroyer = system.addShips("stardestroyer_reactor_breach", 1, this.ship.position, 0)[0];
doomedStarDestroyer.orientation = this.ship.orientation;

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Mon Feb 18, 2013 1:41 pm
by GGShinobi
cim wrote:
for (var x in xs) { assigns the key, not the value, to x (which may surprise you, if you're used to other languages). So what you are then doing is 0.orientation = this.ship.orientation, which won't work. Instead, do

Code: Select all

var doomedStarDestroyer = system.addShips("stardestroyer_reactor_breach", 1, this.ship.position, 0)[0];
doomedStarDestroyer.orientation = this.ship.orientation;
Thank you cim!! It now works perfectly!! :lol:

I've updated the version, the link remains the same (Star Destroyer - Nightmare Version 0.0.1)

Though I should have known that, I already ran into that trap several times when doing my External Repair System... really gotta get this into my head!! :P

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Mon Feb 18, 2013 1:54 pm
by Lestradae
GGShinobi wrote:
I've updated the version, the link remains the same (Star Destroyer - Nightmare Version 0.0.1)
I believe that ...

Code: Select all

missiles = 32;
... is not going to work the devs hardcoded the maximum to 16 - curious myself what happens if you set that value higher.

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Mon Feb 18, 2013 3:17 pm
by GGShinobi
Lestradae wrote:
GGShinobi wrote:
I've updated the version, the link remains the same (Star Destroyer - Nightmare Version 0.0.1)
I believe that ...

Code: Select all

missiles = 32;
... is not going to work the devs hardcoded the maximum to 16 - curious myself what happens if you set that value higher.
Hmm...? I somewhere read that 32 was the maximum... :roll: and it seems to work, the stardestroyer fires missiles like other people... erm... :roll: ...eat peanuts (...err... that is, those "other people" who are not stardestroyers... oh my... what a good comparison :oops: )

But I never took the time to count how many missiles it fired... maybe you are right and it "only" fires 16. :roll:

I've just uploaded a new version, with the added line

Code: Select all

    throw_sparks = yes;
to the wrecked stardestroyer in shipdata.plist... but in my test, it seemed to have no effect... :?

EDIT: I never counted the missiles it fires
EDIT2: "only" instead of only

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Mon Feb 18, 2013 3:40 pm
by Rorschachhamster
Thanks! I'll try that... hope I haven't bit off more than I can chew. :shock: :oops: :wink:

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Tue Feb 19, 2013 1:03 am
by Switeck
Lestradae wrote:
I believe that ...

Code: Select all

missiles = 32;
... is not going to work the devs hardcoded the maximum to 16 - curious myself what happens if you set that value higher.
32 missiles is max for NPCs, 16 missiles is max for players...barring fancy missile bank-switching techniques.

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Tue Feb 19, 2013 10:57 am
by Lestradae
Switeck wrote:
32 missiles is max for NPCs, 16 missiles is max for players...barring fancy missile bank-switching techniques.
Ah, thanks for clearing that up!

Re: [RELEASE] Combat Simulator OXP (1.77 only)

Posted: Thu Feb 12, 2015 2:24 am
by Graham
I've recently installed the Combat Simulator OXP but found an interesting glitch: You can increase your Rating by commiting suicide!

Out of frustration in a fight I couldn't *quite* win (I kept almost killing my opponent, but couldn't land the last shot and he kept zipping off until his shields recovered) I launched a Q-Mine, but, carelessly, ended up caught in my own blast.

So the simulation ended, but when I looked at my screen I saw I'd been awarded an extra kill! I tried this again, deliberately, just to check and it seems that it is repeatable.

Presumably this isn't intended behaviour of the OXP... :shock:

Whilst on the subject, it would also be nice if, instead of only being able to use your current ship, you were able (possibly for a price) to "Test Fly" a range of other ships, ie not only could you select what your opponent would be flying, but you could have an option to choose from a selection of ships with different configurations (or perhaps just the ones which are on sale at that station) to "try before you buy".