Important Message

You are browsing the archived Lancers Reactor forums. You cannot register or login.
The content may be outdated and links may not be functional.


To get the latest in Freelancer news, mods, modding and downloads, go to
The-Starport

Permutation

Do you want to start editing Freelancer, but have no clue where to begin? This is the place for you to find things and talk about getting started on Freelancer Modding

Post Tue Sep 25, 2007 2:34 pm

Permutation

Please what exactly does the "permutation" parameter control in the encounters/etc folder?

Beware pirates bearing gifts!
What do you get when you drop a piano down a mine?
a flat minor.

Post Fri Oct 12, 2007 9:34 pm

Permutation means the control of formations to ships. For example, permutation = 0, 3 means that it can have up to 3 escorts and a minimum of no escorts.

Say, if you put: permutation = 10, 20, then there'll be a minimum of 10 escorts and a maximum of 20 escorts for that ship.

Hope you understand now, good luck modding Freelancer.

Post Sat Oct 20, 2007 3:53 pm

What?!!

NO! Tut! tut! tut!

Absolute Twaddle!!

You are confusing it with ship_by_class:-
<pre><font size=1 face=Courier>
[EncounterFormation
ship_by_class = 1, 2, sc_battleships <-- 1 or 2 battleships
pilot_job = assault_leader_job
make_class = wanderer
ship_by_class = 0, 2, sc_cruisers <-- 0 to 2 cruisers
pilot_job = assault_job
make_class = wanderer
ship_by_class = 2, 6, sc_fighters <-- 2 to 6 fighters
pilot_job = assault_job
make_class = wanderer
formation_by_class = battleships
behavior = wander
arrival = cruise
allow_simultaneous_creation = false
zone_creation_distance = 0
times_to_create = infinite
[EncounterFormation
ship_by_class = 1, 1, sc_fighters <-- 1 fighter
pilot_job = assault_leader_job
make_class = wanderer
ship_by_class = 4, 4, sc_fighters <-- 4 fighters
pilot_job = assault_job
make_class = wanderer
formation_by_class = fighters
behavior = wander
arrival = cruise
allow_simultaneous_creation = true
zone_creation_distance = 0
times_to_create = infinite
[Creation
permutation = 0, 3 <-- encounter formation 0 (1st one) every 3rd spawn slot
permutation = 1, 3 <-- encounter formation 1 (2nd one) every 3rd spawn slot
</font></pre>

THIS is what permutation means:

The encounter formations in the ini file are invisibly numbered, 0 for the first, 1 for the second, 2 for the third, 3 for the fourth etc.

The second number is the spawn slot interval, for want of a better description. FL runs a timer which counts spawn intervals, based on the zone relief time and repop time. I haven't investigated these fully yet to be able to tell you exactly what time it is counting. But every x seconds, there is a spawn slot.

In Permutation = 0, 3, the first encounter formation (0) will be generated every 3rd spawn slot. If you have more than one encounter formation in the same encounter ini file, a second permutation will be needed, e.g. 1, 3.

If your zone density allows the total number of ships, it will spawn both formations at the first spawn slot. Then it will wait 3 slots before spawning the first formation again.

If you make 3 encounter formations and set:
0,1
1,3
2,3

then you will see formation 0 only, and it will spawn at every spawn slot, up to the maximum ships allowed in your zone. The 2nd and 3rd formations may never spawn because FL scans this list top to bottom, and at the 3rd spawn times it will generate formation 0 first because it's set to spawn at every interval.

If you are bold and make 4 encounter formations then things start to go wrong because for some reason the game engine doesn't handle the timing correctly. I tried 4 formations with permutations = 0,4 1,4 2,4 3,4 and no npcs were spawned at all.

So stick with 3 formations max and make the permutations:
(0,3)
(1,3)
(2,3)
and you will see all of the formations spawn in sequence. After the 3rd formation you will see the first one again, then the 2nd and then the 3rd again, and the loop will continue while you are in the encounter zone.

If you set different difficulty for each ship type and make your formations one level less for each subsequent formation, then you will see the different ship types in sequence.

There is no point in having more than one formation if the ship types are all the same, except if you want different numbers of ships flying in wings.



Roleplay: - the art of self-deceipt!

Post Sat Oct 20, 2007 8:11 pm

wow - good to know about the permutations, I think this has not been explained yet

Post Tue Oct 23, 2007 3:40 pm

No, its not my original info, I don't claim any credit for it.

It was in one or two of the tutorials on encounters.

I just played with extreme numbers until I understood it.


;o)

Roleplay: - the art of self-deceipt!

Post Mon Oct 29, 2007 1:57 pm

Thank you. That is very revealing.

Beware pirates bearing gifts!
What do you get when you drop a piano down a mine?
a flat minor.

Post Wed Oct 31, 2007 4:58 am

Return to Freelancer Modding for Beginners Forum