I'm making a kind of civilization style game, and at the start of the game players get to pick traits that they specialize in with their civilization.
But what I'm asking isn't how to do this, but rather how to make this clean and quick, I want to have certain behaviors on the units that only enable when the players have these traits, and I intend to grant players the ability to enable these traits by spending points at the start of the game.
So what I'm asking is, after the player presses the button to spend the point, whats the cleanest kind of boolean statement I can use to enable the behaviors, units, abilities, etc that go along with the trait that they have decided?
An example is I could just have the trigger raise an upgrade that enables alot of things, or create a unit that does nothing but act as a tech requirement. But I want to know if anyone knows of an even cleaner way to make it happen in Starcraft 2 before I start using the quick and simple methods.
The cleanest way is probably use the same tech upgrade system like blizzard did. Create or duplicate an upgrade object from the data editor. They can change a lot of thing trigger cant. Then when you want to enable/disable upgrade, use this trigger
Aha I see, the upgrades themselves apply changes to already existing abilities, blizzard really did think ahead with this particular feature.
This will make my project much easier to work on.
Edit: Unbelievable, it actually allows me to adjust cost and build times!? I was about ready to lose hope, guess blizzard didn't let me down after all.
I'm making a kind of civilization style game, and at the start of the game players get to pick traits that they specialize in with their civilization.
But what I'm asking isn't how to do this, but rather how to make this clean and quick, I want to have certain behaviors on the units that only enable when the players have these traits, and I intend to grant players the ability to enable these traits by spending points at the start of the game.
So what I'm asking is, after the player presses the button to spend the point, whats the cleanest kind of boolean statement I can use to enable the behaviors, units, abilities, etc that go along with the trait that they have decided?
An example is I could just have the trigger raise an upgrade that enables alot of things, or create a unit that does nothing but act as a tech requirement. But I want to know if anyone knows of an even cleaner way to make it happen in Starcraft 2 before I start using the quick and simple methods.
The cleanest way is probably use the same tech upgrade system like blizzard did. Create or duplicate an upgrade object from the data editor. They can change a lot of thing trigger cant. Then when you want to enable/disable upgrade, use this trigger
http://wiki.sc2mapster.com/galaxy/triggers/set-upgrade-level-for-player/
go here in the wiki for more similar action
http://wiki.sc2mapster.com/galaxy/triggers/category-tech-tree/
@progammer: Go
Aha I see, the upgrades themselves apply changes to already existing abilities, blizzard really did think ahead with this particular feature.
This will make my project much easier to work on.
Edit: Unbelievable, it actually allows me to adjust cost and build times!? I was about ready to lose hope, guess blizzard didn't let me down after all.