Fractal Softworks Forum

Please login or register.

Login with username, password and session length

Author Topic: Sting type: Spawnpoint  (Read 1324 times)

Dibuk

  • Lieutenant
  • **
  • Posts: 71
    • View Profile
Sting type: Spawnpoint
« on: October 28, 2014, 08:13:49 AM »

Sooo, new version, new compability issues. Everyone is happy.

This is from a Spawnpoint that used to work.
Code
	protected CampaignFleetAPI spawnFleet() {
//if ((float) Math.random() < 0.5f) return null;

      --->    String type = null;
float r = (float) Math.random();

Yeah, that little line causes me much grief. In the last version it were fine to give it a null value, now I have no idea what to enter in the string value. The vanilla factions have things like "patrol" or "guard" entering these things dosen't work as my faction does not have a variable set up for those values (duh).

So where does one set up a "guard"-fleet? I'm pretty damn sure I've looked everywhere.

(PS: the pesky independents does have a null value, I just notised...)

EDIT: I just notised that the color did not work (derp), it's about the line with the arrow.
« Last Edit: October 28, 2014, 08:52:40 AM by Dibuk »
Logged

Dark.Revenant

  • Admiral
  • *****
  • Posts: 2806
    • View Profile
    • Sc2Mafia
Re: Sting type: Spawnpoint
« Reply #1 on: October 28, 2014, 08:34:42 AM »

FleetFactory.createGenericFleet (just give it a little extra stability and a bunch of fleet points).
Logged