Get the Desktop App for Battle.net Now
- All your games in 1 place
- Log in once
- Automatic game updates
I want make this so a player can only warp-in/train/spawn 15 workers throughout the game.
I was fooling around with protoss and
I was able to limit the number of workers by going to: warp in probe ability > Info charge count max > I set this to 15 (max worker)
> Info charge start > i set this to the same as max (how many times i can use the ability)
> Info charge use > set it to 1 so it will count -1 from usage
All works neatly with 1 little bump!
If a worker dies the " Info charge use " wont count it as +1 to info charge use meaning I can only build 15 workers and if they all die I wont be able to replace them.
How do I fix this?
Hope I made sence... :)
I'd suggest using requirement data since it sounds like you want to limit them to 15 at a time and that's easy to hookup with requirements.
Requirements for abilities are assigned in the Ability portion of the data editor. These can be assigned per command for all ability types, so you can have unique requirements for each button, or have them all share the same requirements; up to you.
There are two types of requirements: use and show. Use requirements will disable a button if they are not met; show requirements will hide the button if they aren't met.
If you want all types of workers to be considered as a group, then you can use a "sum" requirement node that combines the "count" requirement nodes of all types you want to check for. Another method would be to assign the same tech alias in the unit data for each of the worker types you want to be equivalent and then you can use a single count node and compare the count to whatever you want.
If you haven't worked with requirement data a lot, I'd suggest looking at how requirements are setup for something similar. For example, there is a requirement on the Nexus to prevent more than one Mothership from being constructed. You'd basically want to mimic that setup to start and make tweaks to it to suit your data (basically choosing different unit types rather than the Mothership and a different total count).
Cool thx for the reps guys!!
so this is what i did :
new requirement-->use-->Less than-->count unit-->probe-->queued or better-->constant-->15
This works great!
The only thing tho is when I add those digits (15/15/1) to the Info Charge the #15 will show up on the probe build icon and will count how many probes I built, now when i destroy 1 it wont show that I can build 1 more (only the number won't show, the icon goes colored from grayed ).
so it counts down the queued ones but wont count up if 1 killed.
Can u help me out ?
Edited by Bushido on 11/13/2012 11:18 PM PST
There is one way to display the current available scv count.
You can imitate the nuke abilty. nuke have max limit per Ghost Academy, while you can replenish them after they be used. And it would show the current nuke amount on ghost's calldown ability button.
What you need to do is reverse the Magazine number.
The only problem is Train ability cannot display calldown number, so you may need to use a effect ability to simulate the button
Edited by Renee on 11/15/2012 7:58 PM PST
Ye it looks a bit complicated right now. I want to spend time on other things that needs to be done so I might get back to this later.
And since this is a TD map I removed the supplies on all units .
But now I added (+) 15 to the town centers and -1 for probe/drone/SCV.
This way the supply count will show how many worker a player has, elliminating the need of the counter on the icon itself (and the requirement for that matter)
Edited by Bushido on 11/15/2012 4:12 PM PST
Not sure if anyone still needs to know this info but, heres how you limit the number of workers you can build, and be able to build another if one gets killed or used up (ie zerg drone mutating into a building)
Give it a name, doesnt matter what it is, but I suggest using the name of the unit that you are limiting the number built of. I.E Drone, Probe or SCV.
Next with your new Requirement selected in the left box, in the right box you should have 2 green items and the rest is grayed out.. If this is what you see you're on the right track
on the right is a drop down menu, select it and select 'Not Equal to' (Here also you may want to add a tool tip as to why the player can no longer build these units. This tooltip will show up once the requirements are met. So something like "Must have fewer than 15 Drones" for example)
Now to add the requirement you made to a building process.
In this window there is a bunch of changes you can make, resource cost, build time, recharge time, charges avaliable etc.
You can copy and paste that Requirement and modify it to fit other units if you wish.
Threats of violence. We take these seriously and will alert the proper authorities.
Posts containing personal information about other players. This includes physical addresses, e-mail addresses, phone numbers, and inappropriate photos and/or videos.
Harassing or discriminatory language. This will not be tolerated.