Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Pages: [1] 2

Author Topic: Random Sector v0.2.2a ( for 0.65.2a)  (Read 19503 times)

Debido

  • Admiral
  • *****
  • Posts: 1183
    • View Profile
Random Sector v0.2.2a ( for 0.65.2a)
« on: November 04, 2014, 02:15:06 PM »


Download Random Sector 0.2.2a
(Requires LazyLib 2.0b)
(Bitbucket Repository Bitbucket Source)

Not random enough? How about this! (Time accelerated)


Random Sector is a 'utility' mod that does not in any way add any content to the game, no new ships, no new systems, or factions. What it does do however is randomise the experience on each game in some way.

This first version will randomise the location of systems when you start a new game, in future I may add features such as market condition randomisation, or even the planet and satellites orbits.

So this mod is for those of you whom are bored with the current star system layout and would like to mix things up a bit. The great thing is that it also works with mod factions that are already out there. In future though, I may also make it so that faction mods are detected and that those with multiple star systems are located in clusters near each other.

For those who use dev mode, it will also randomise the star systems upon each game load. ;-)




Credits
Scripting: Debido
Concept: Tartiflette
Shenanigans/Feedback: Starsector Mod Squad (you know who you are)

Version Log
Version 0.2.2a (November 10, 2014):
- Fixed up bug in saving elliptical orbit data
- Added onApplicationLoad check for LazyLib


Version 0.2 (November 8, 2014):
- Added elliptical orbits

Version 0.1 (November 5, 2014):
- Initial release
- Randomised location of star systems on new game
« Last Edit: February 18, 2015, 12:12:27 AM by Debido »
Logged

CopperCoyote

  • Captain
  • ****
  • Posts: 451
    • View Profile
Re: Random Sector v0.1(0.65.1a)
« Reply #1 on: November 07, 2014, 02:55:36 AM »

This is pretty neat. It'll make the gravy run of food to Sindaria tougher. Usually.

Quote
For those who use dev mode, it will also randomise the star systems upon each game load. ;-)

Because of this I was able to add it into an already existing game by enabling devmode loading it up, and then saving and exiting then disabling devmode.

This is the first randomization:

Spoiler

looks like it'd be a gravy run again.
Edit: I forgot to point out how the ships are all where around where the vanilla star locations were.
[close]

I exited Starsector an loaded it up a couple times to get a more interesting map. Now the Eos <-> Askonia route is long and takes me through the center of the map, and potentially through more danger. I didn't take a screen shot of the newest map. I want to let the ship paths normalize first.

So far it appears adding it into an existing game is just as stable as normal.
« Last Edit: November 07, 2014, 02:57:39 AM by CopperCoyote »
Logged
Itches are scratched. Back-rubs are savored.

Debido

  • Admiral
  • *****
  • Posts: 1183
    • View Profile
Re: Random Sector v0.1(0.65.1a)
« Reply #2 on: November 07, 2014, 03:58:03 AM »

I'm glad to hear it is adding some more variety to your game and mixing up the trade routes some. You'd be surprised at just how small and simple the code is. Anyway I suppose we should get used to random system locations and such for when SS goes procedural.
Logged

CopperCoyote

  • Captain
  • ****
  • Posts: 451
    • View Profile
Re: Random Sector v0.1(0.65.1a)
« Reply #3 on: November 07, 2014, 07:40:32 PM »

I seem to recall reading somewhere that there will be some hand placed star systems (like the ones in vanilla now).

Would it be hard to limit how far the random the placed systems are moved? My new system is quite spread out, and it shows a weakness in the intel map.
Pictures:
New system
Spoiler
[close]
Intel
Spoiler
[close]

I use the intel tab a lot so it's inconvenient to have all the icons floating on the edges because the system is off the map.

Would it be possible to add in mod factions by enabling dev mode, and letting it spawn their systems that way? I imagine adding systems is different than moving them.
Logged
Itches are scratched. Back-rubs are savored.

Debido

  • Admiral
  • *****
  • Posts: 1183
    • View Profile
Re: Random Sector v0.1(0.65.1a)
« Reply #4 on: November 07, 2014, 09:33:21 PM »

Hmmm, I see what you mean now with the map. I can certainly limit the randomisation parameters so that it stays within the Intel map.

Also I have developed the randomiser a little bit more so...well...you'll see soon enough, if you like the fact that the trade routes changes on each load, what if they changed....all the time?

As for randomising without devmode, I see where you're coming from. I think it might be possible to say, add a space station at the centre of the hyperspace map, and in an interaction dialogue you can request a new randomised system.

However I've never touched interaction dialogue scripts before, I think I'll need someone's help to do that.
Logged

CopperCoyote

  • Captain
  • ****
  • Posts: 451
    • View Profile
Re: Random Sector v0.1(0.65.1a)
« Reply #5 on: November 07, 2014, 10:56:12 PM »

Quote
Also I have developed the randomiser a little bit more so...well...you'll see soon enough, if you like the fact that the trade routes changes on each load, what if they changed....all the time?

Ooh! Like they slowly creep about? That'd make having enough fuel even more critically important. As it stands now I have a capital fuel tanker to feed my 6 atlases for a round trip from askonia to eos and back via one of the other systems (so the path looks like triangles). I find myself desperately trying to find more buffalos because they're more fuel efficient and less supply intensive.

It'd be easy to handwave too. By saying that hyperspace stretches and contracts over time it can cause the apparent location of a particular system to drift over time.
Logged
Itches are scratched. Back-rubs are savored.

Debido

  • Admiral
  • *****
  • Posts: 1183
    • View Profile
Re: Random Sector v0.1(0.65.1a)
« Reply #6 on: November 07, 2014, 11:02:36 PM »

Well, what's really made my job 10x harder now is taking into consideration the intel map. I had everything to go with everything orbiting around the centre just fast enough that you can still fall in to a star system if you run out of fuel.

However the Intel map is is rectangular, meaning I have to figure out an elliptical orbit...which is a magnitude of order more difficult. If it were a square map and it were sized to the +/- 20,000 of the hyperspace map we'd be golden.
Logged

Debido

  • Admiral
  • *****
  • Posts: 1183
    • View Profile
Re: Random Sector v0.2a(0.65.1a)
« Reply #7 on: November 08, 2014, 01:29:41 AM »

Alright! Uploaded version 0.2a. Now has elliptical orbits. Have fun!

« Last Edit: November 08, 2014, 01:41:59 AM by Debido »
Logged

CopperCoyote

  • Captain
  • ****
  • Posts: 451
    • View Profile
Re: Random Sector v0.2a(0.65.1a)
« Reply #8 on: November 09, 2014, 05:20:03 AM »

I got an error while trying to load my game:

Spoiler
120641 [Thread-5] INFO  com.fs.starfarer.campaign.save.CampaignGameManager  - Loading stage 35
120812 [Thread-5] ERROR com.fs.starfarer.combat.O0OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO  - java.lang.NullPointerException
java.lang.NullPointerException
   at db.randomsector.DB_RandomiseSystemLocations.advance(DB_RandomiseSystemLocations.java:143)
   at com.fs.starfarer.campaign.CampaignEngine.advance(Unknown Source)
   at com.fs.starfarer.campaign.save.CampaignGameManager.o00000(Unknown Source)
   at com.fs.starfarer.title.B.dialogDismissed(Unknown Source)
   at com.fs.starfarer.ui.oO0O.dismiss(Unknown Source)
   at com.fs.starfarer.ui.impl.J.dismiss(Unknown Source)
   at com.fs.starfarer.campaign.save.LoadGameDialog.actionPerformed(Unknown Source)
   at com.fs.starfarer.ui.thisnew.super(Unknown Source)
   at com.fs.starfarer.ui.null.processInput(Unknown Source)
   at com.fs.starfarer.ui.O0Oo.o00000(Unknown Source)
   at com.fs.starfarer.B.void.class$super(Unknown Source)
   at com.fs.A.oOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOO.Ò00000(Unknown Source)
   at com.fs.starfarer.combat.O0OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO.super(Unknown Source)
   at com.fs.starfarer.StarfarerLauncher$2.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
[close]

I'm running this mod ICE SRA and tradewinds 2

I can't recall what i was doing last night when i saved.
Logged
Itches are scratched. Back-rubs are savored.

Debido

  • Admiral
  • *****
  • Posts: 1183
    • View Profile
Re: Random Sector v0.2a(0.65.1a)
« Reply #9 on: November 09, 2014, 03:22:58 PM »

Thanks for the notification. I'll look into it straight away.
Logged

Debido

  • Admiral
  • *****
  • Posts: 1183
    • View Profile
Re: Random Sector v0.2a(0.65.1a)
« Reply #10 on: November 09, 2014, 03:50:39 PM »

Well I can see where the NPE is occurring, I'm just not sure why it is null in the first place. Let me send you a private hotfix version. Let me know if it helps.
Logged

Sundog

  • Admiral
  • *****
  • Posts: 1727
    • View Profile
Re: Random Sector v0.2a(0.65.1a)
« Reply #11 on: November 09, 2014, 04:45:05 PM »

Debido, I was able to reproduce this twice (once with ICE enabled and once without) by starting a new game, saving, exiting, and loading/continuing.

Debido

  • Admiral
  • *****
  • Posts: 1183
    • View Profile
Re: Random Sector v0.2a(0.65.1a)
« Reply #12 on: November 09, 2014, 05:06:24 PM »

Alright, I see where I !@#$#% up, you won't have an issue if you run it in devmode. I didn't see the bug because I always use devmode, easy fix though.
Logged

Debido

  • Admiral
  • *****
  • Posts: 1183
    • View Profile
Random Sector v0.2.2a (*HOTFIX*) ( for 0.65.1a)
« Reply #13 on: November 09, 2014, 09:46:14 PM »

Uploaded version 0.2.2a. Fixed the loading issue, this *should* also fix up any old saves as well, so your game save isn't broken.

*Warning broken saves will have their system re-randomised to conform to the new save*

« Last Edit: November 09, 2014, 09:54:50 PM by Debido »
Logged

CopperCoyote

  • Captain
  • ****
  • Posts: 451
    • View Profile
Re: Random Sector v0.2.2a (*HOTFIX*) ( for 0.65.1a)
« Reply #14 on: November 09, 2014, 10:08:56 PM »

I appreciate the fix. I was admittedly only level 10, but it's still nice to have my progress.
Logged
Itches are scratched. Back-rubs are savored.
Pages: [1] 2