Well transferring colonists isn't "automatic", you have to detect when something like an evac transport comes close to your base or whereever, like with an Evac trigger.
In the trigger callback you'd need to do something to increase the other player's colonist count and decrease yours, for example a truck with 5 workers
// Player 0 - you, Player 1 - recipient
Player[1].SetWorkers(Player[1].Workers()+5);
Player[0].SetWorkers(Player[0].Workers()-5);
And you'd probably have to have checks to make sure the colonist counts can't go below zero, etc.
That's the easiest way I can think of to transfer colonists.
And yeah, after you get it in a semi releasable state it would be nice to see source code. That way people can look at it and learn from it (there aren't enough colony games already).
Well transferring colonists isn't "automatic", you have to detect when something like an evac transport comes close to your base or whereever, like with an Evac trigger.
In the trigger callback you'd need to do something to increase the other player's colonist count and decrease yours, for example a truck with 5 workers
// Player 0 - you, Player 1 - recipient
Player[1].SetWorkers(Player[1].Workers()+5);
Player[0].SetWorkers(Player[0].Workers()-5);
And you'd probably have to have checks to make sure the colonist counts can't go below zero, etc.
That's the easiest way I can think of to transfer colonists.
And yeah, after you get it in a semi releasable state it would be nice to see source code. That way people can look at it and learn from it (there aren't enough colony games already).
Same thing i've used in Renegades, mission 3
didn't even notice there was a post about this.
TethysGame::AddMessage(residence,"Colonists transferred safely.",0,178);
plHuman.SetScientists(plHuman.Scientists()+5);
plHuman.SetWorkers(plHuman.Workers()+10);
plHuman.SetKids(plHuman.Kids()+10);
:lol: almost exactly the same