Author Topic: Victory Condition?  (Read 1468 times)

Offline spirit1flyer

  • Hero Member
  • *****
  • Posts: 621
Victory Condition?
« on: September 25, 2005, 10:23:24 AM »
what do I put to make the Victory Condition into a population goal? and not just a kill enemy goal?

CreateLastOneStandingVictoryCondition();

return 1; // return 1 if OK; 0 on failure

spirit
"Until you stalk and overrun You can't devour anyone"


Loyal Xfir supporter

Offline BlackBox

  • Administrator
  • Hero Member
  • *****
  • Posts: 3093
Victory Condition?
« Reply #1 on: September 25, 2005, 11:55:45 AM »
What'd you'd do is remove the CreateLastOneStandingVictoryCondition(); line above.

Then code like this: (Example, 400 colonists for player 0; Just change the 400 and 0 in the first line if you want)
Code: [Select]
Trigger population = CreateResourceTrigger(1, 1, resColonists, 400, 0, cmpGreaterEqual, "NoResponseToTrigger");

CreateVictoryCondition(1, 0, population, "Have 400 Colonists.");

You can tweak the 400 and 0 in the first line as you want, to specify the amount and player ID (0 is usually the human in a colony game), and you can tweak the text in the 2nd line if you wish.

Hope it helps!
« Last Edit: September 25, 2005, 11:56:02 AM by op2hacker »

Offline spirit1flyer

  • Hero Member
  • *****
  • Posts: 621
Victory Condition?
« Reply #2 on: September 25, 2005, 12:44:35 PM »
yes thanks  B)  
That will let me do just what I want  :)


Spirit
"Until you stalk and overrun You can't devour anyone"


Loyal Xfir supporter