WitchSpace ship populating

An area for discussing new ideas and additions to Oolite.

Moderators: another_commander, winston

User avatar
Cody
Sharp Shooter Spam Assassin
Sharp Shooter Spam Assassin
Posts: 14291
Joined: Sat Jul 04, 2009 9:31 pm
Location: Corke's Drift
Contact:

Re: WitchSpace ship populating

Post by Cody »

Killer Wolf wrote:This hasn't happened before and it only seems to have happened once but at the same time i'm 90% sure i got a flying-in-reverse ship, cos a viper appeared at great speed and his engine plume was on the wrong side for his direction of travel
This reminded me of an escape capsule I scooped a while back (dev version 1.75.0.3934)... it wasn't flying backwards exactly, but it looked most odd:

Image
I dreamed I saw the silver spaceships flying, in the yellow haze of the sun
There were children crying and colors flying, all around the chosen ones
All in a dream, all in a dream, the loading had begun
Flying Mother Nature's silver seed to a new home
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5510
Joined: Thu Jun 12, 2008 6:55 pm

Re: WitchSpace ship populating

Post by Thargoid »

To go back to KW's scripting question - spawn: is (almost) one of the JS console macros, not a JS command in and of itself. When used via the console (:spawn PARAM) it actually does:

system.addShips(PARAM, 1, player.ship.position, 10000);

where PARAM is in this case the role of the ship to be spawned. If you replace your

spawn: this.role, this.count;

with

system.addShips(this.role, this.count, player.ship.position, 10000);

then you will get the ships appearing (in this case within a 10km radius sphere of your ship).

Given your command that didn't work was system ships and you're not actually in a system...? ;)
User avatar
Mauiby de Fug
---- E L I T E ----
---- E L I T E ----
Posts: 824
Joined: Tue Sep 07, 2010 2:23 pm

Re: WitchSpace ship populating

Post by Mauiby de Fug »

El Viejo wrote: This reminded me of an escape capsule I scooped a while back (dev version 1.75.0.3934)... it wasn't flying backwards exactly, but it looked most odd
I've scooped a bunch of pods like that. As far as I could tell at the time, they were trying to turn and head towards the planet... At least, that was my assumption!
User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Re: WitchSpace ship populating

Post by Eric Walch »

Killer Wolf wrote:

Code: Select all

this.shipWillExitWitchspace = function() 
{
  if(system.isInterstellarSpace && Math.random() < .95) 
  {
     spawn: this.role, this.count; 
     log("testscript.spawn", "Generated " + this.count + " " + this.role + " for testing purposes."); 

  }
}
i used "spawn" because the "system.legacy_addSystemShips" bit didn't work : well, the log said it worked, but i'll be buggered if i know where the Spectres were spawning :-/
The log is not telling anything useful here. spawn() needs a location. Or more precice, it needs an existing ship as origin. e.g. player.ship.spawn(this.role, this.count) That would spawn the ships very close around your location.

But better use the code Thargoid showed above.
User avatar
JensAyton
Grand Admiral Emeritus
Grand Admiral Emeritus
Posts: 6657
Joined: Sat Apr 02, 2005 2:43 pm
Location: Sweden
Contact:

Re: WitchSpace ship populating

Post by JensAyton »

El Viejo wrote:This reminded me of an escape capsule I scooped a while back (dev version 1.75.0.3934)... it wasn't flying backwards exactly, but it looked most odd:
Escape pods are launched with a velocity similar to the parent ship’s, then start pushing for home at maximum thrust (see homeAI.plist). However, escape pods have very weak engines (thrust = 5).

Yes, folks, it’s *dun dun DUN!* Oolite’s Newtonian flight model, exposed for the world to see.
User avatar
Phantom Hoover
Dangerous
Dangerous
Posts: 100
Joined: Mon Mar 22, 2010 9:06 pm

Re: WitchSpace ship populating

Post by Phantom Hoover »

If the ship was running on injectors when it was gunned down, this can lead to the entertaining situation wherein the escape pod is flying so fast that hyperspeed is required to catch up with it.
User avatar
Killer Wolf
---- E L I T E ----
---- E L I T E ----
Posts: 2043
Joined: Tue Jan 02, 2007 12:38 pm

Re: WitchSpace ship populating

Post by Killer Wolf »

Thargoid wrote:To go back to KW's scripting question - spawn: is (almost) one of the JS console macros, not a JS command in and of itself. When used via the console (:spawn PARAM) it actually does:

system.addShips(PARAM, 1, player.ship.position, 10000);

where PARAM is in this case the role of the ship to be spawned. If you replace your

spawn: this.role, this.count;

with

system.addShips(this.role, this.count, player.ship.position, 10000);

then you will get the ships appearing (in this case within a 10km radius sphere of your ship).

Given your command that didn't work was system ships and you're not actually in a system...? ;)
cheers, i'll give that a try.
but, as i said, how come the "system ships" thing spawned the Cobras? i wasn't in a systems but it worked for them! i only messed w/ the Spectre script, swapping between addsystemship/spawn, but like i say it was doing odd things like triggering the Cobras when i exited WS too, when in fact the script says to activate on launch.
UK_Eliter
---- E L I T E ----
---- E L I T E ----
Posts: 1142
Joined: Sat Sep 12, 2009 11:58 pm
Location: Essex (mainly industrial and occasionally anarchic)

Re: WitchSpace ship populating

Post by UK_Eliter »

Dear all

I haven't read this thread properly, but I thought it might be the place to say the following. It would aid 'immersion' if (1) there were not always Thargoids, and indeed navy, in witchspace, and (2) if a certain maneouvre did not always result in a witchjump. What d'ya think? My suggestion is that sometimes one find merely empty space, at other times one finds Thargoids, and at other times one finds both Thargoids and navy. (And then of course there are the generation ships). Perhaps I myself could alter the relevant behaviour.

But perhaps this is what is called 'hijacking a thread'? If so, sorry.
User avatar
Phantom Hoover
Dangerous
Dangerous
Posts: 100
Joined: Mon Mar 22, 2010 9:06 pm

Re: WitchSpace ship populating

Post by Phantom Hoover »

The "maximum climb misjumps" is justified by the witchspace wormhole being possible to fly out of, which dumps you in interstellar space. Agree on the Thargoid and Naval presence, though.
User avatar
Kaks
Quite Grand Sub-Admiral
Quite Grand Sub-Admiral
Posts: 3009
Joined: Mon Jan 21, 2008 11:41 pm
Location: The Big Smoke

Re: WitchSpace ship populating

Post by Kaks »

You can always remove thargoids from interstellar space via a fairly small oxp (I might find the time to code that for Tuesday) thing is, I get the impression there's quite a few oxps that assume thargoids there so making NoThargoids.oxp (tm pending) play nice with all of them might well prove difficult...
Hey, free OXPs: farsun v1.05 & tty v0.5! :0)
User avatar
Killer Wolf
---- E L I T E ----
---- E L I T E ----
Posts: 2043
Joined: Tue Jan 02, 2007 12:38 pm

Re: WitchSpace ship populating

Post by Killer Wolf »

That did the trick Thargoid, cheers mate :-)

now : the Spectres have a route1PatrolAI (picked simply cos it's a Viper typical thing) : i was hoping it would make them see the Thargoids and actively engage them, but as i was admiring my success and rubbing my paws anticipating some kick-ar$e screenshots, 6 of them jumped out in unison!! tw@s left me w/ four motherships! >:-/
is this typical? i kinda thought Thargoids would be treat as enemies/fugitives are and engaged?
i also noticed an odd one w/ the Nest : a bunch of Wasps were sat firing at the Nest and picking off other Wasps, though the others didn't seem bothered and sat there w/out fighting back.

lastly, a bleb that musta been a one off, cos it hasn't replicated so far ~
in WS, the Spectres jumped out and i followed one through its cloud. coming out, no sign of it. went to the planet, docked, fueled, launched and noticed this in the log :

[script.javaScript.exception.notFunction]: ***** JavaScript exception (System Redux 1.2 1.2): TypeError: system.mainPlanet.setTexture is not a function
[testscript.spawn]: Generated 3 c4 for testing purposes.
[script.load.world.listAll]: Loaded 14 world scripts:
Anarchies 2.3
AsteroidStorm 4.00
hoopy_casino 1.2
oolite-cloaking-device 1.75
oolite-constrictor-hunt 1.75
oolite-nova 1.75
oolite-thargoid-plans 1.75
oolite-trumbles 1.75
Random_Hits 1.4
Spawn-c4 1.0.1
Spawn-nest 1.0.1
Spawn-sothis 1.0.1
Spawn-spectre 1.0.1
System Redux 1.2 1.2
[exception]: ***** Exception during [updateTimers] in -[PlayerEntity update:] : NSInvalidArgumentException : GSCInlineString(instance) does not recognize isScheduled *****
[exception]: ***** Exception during [update:entity [<PlayerEntity 0x6b949f8>{"Vampire MkV ~ Spectre" position: (72727.4, -98769.8, 664079) scanClass: CLASS_PLAYER status: STATUS_DOCKED}]] in [Universe update:] : NSInvalidArgumentException : GSCInlineString(instance) does not recognize isScheduled *****


i assume it's referring to Spectre still in existence from the first time around as no others should have spawned from my launch.
Post Reply