[suggestion][idea][request][annoyingtag] Supply Cap
Moderator: Moderators
- Forboding Angel
- Evolution RTS Developer
- Posts: 14673
- Joined: 17 Nov 2005, 02:43
[suggestion][idea][request][annoyingtag] Supply Cap
Before the groaning starts, let me point out that supply caps perform a very real function other than just limiting attacking units. Anyone that has played *craft knows this, and anyone who isn't a noob in *crap understands it's function and how it dramatically affects gameplay by forcing you to be much more strategic and tactical in your unit choices rather than setting up a factory queue and spamming that same queue for the next 30 minutes.
Does anyone have any plans to create this ability? Does it already exist?
Ideally unit supply could be set in customparams of each unitdef.
Does anyone have any plans to create this ability? Does it already exist?
Ideally unit supply could be set in customparams of each unitdef.
Re: [suggestion][idea][request][annoyingtag] Supply Cap
why isn't this in game development?
Re: [suggestion][idea][request][annoyingtag] Supply Cap
AllowUnitCreation allows to block a units creation.
So just keep count of things, something like
unitdefs like
So just keep count of things, something like
Code: Select all
local maxPop = {} -- maximum per [teamID]
local currPop = {)-- current per [teamID]
local hardLimit = 200 --no matter how many overlords, this is maximum of maximum
*some loop to set everything to zero*
function gaddget:UnitFinished (blabla)
local cp = UnitDefs[unitDefID].customParams
if not cp then return end
maxPop[teamID] = maxPop[teamID] + cp.providepop or 0
currPop[teamID] = currPop[teamID] - cp.usepop or 0
end
function gaddget:UnitDestroyed (blabla)
local cp = UnitDefs[unitDefID].customParams
if not cp then return end
maxPop[teamID] = maxPop[teamID] - cp.providepop or 0
currPop[teamID] = currPop[teamID] + cp.usepop or 0
end
function gaddget:AllowUnitCreation (blabla)
local cp = UnitDefs[unitDefID].customParams
if not cp then return true end
if currPop[teamID] + cp.usepop > hardLimit then return false end
if currPop[teamID] + cp.usepop - cp.providepop > maxPop[teamID] then return false end
return true
end
Code: Select all
supply depot:
customParams =
{
providepop = 10,
}
space marine:
customParams =
{
usepop = 1,
}
- Forboding Angel
- Evolution RTS Developer
- Posts: 14673
- Joined: 17 Nov 2005, 02:43
Re: [suggestion][idea][request][annoyingtag] Supply Cap
Granted, this wouldn't show anything guiwise... but is it really that simple? O_o
Too bad I'm not at home. I'd tackle this in a heartbeat.
3 more weeks
Does unitcreated take into account units that are given?
How to take into account units that are given? Would it just be yet another call like the others?
Too bad I'm not at home. I'd tackle this in a heartbeat.

3 more weeks
How to take into account units that are given? Would it just be yet another call like the others?
Last edited by Forboding Angel on 04 Jun 2013, 18:59, edited 2 times in total.
Re: [suggestion][idea][request][annoyingtag] Supply Cap
http://springrts.com/wiki/Units-UnitDef ... Restricted ??
Or knorke's way if you don't want it per-unitdef.
Or knorke's way if you don't want it per-unitdef.
- Forboding Angel
- Evolution RTS Developer
- Posts: 14673
- Joined: 17 Nov 2005, 02:43
Re: [suggestion][idea][request][annoyingtag] Supply Cap
Not the same, Flozi. Have you played *Crap before?
Re: [suggestion][idea][request][annoyingtag] Supply Cap
No but if knorkes system is what you want then I imagine it is much like AoE. Also, BTL kinda has a system like this but it is based on energy, which is only produced/consumed by buying and losing units where some units 'weigh' more than others.
edit; for Given/Taken:
I might have mixed up the argument order but hopefully you get the idea (just forward the args to the other functions you already set up)
edit; for Given/Taken:
Code: Select all
function gadget:UnitGiven(unitID, unitDefID, newTeamID, oldTeamID)
gadget:UnitDestroyed(unitID, unitDefID, oldTeamID)
gadget:UnitCreated(unitID, unitDefID, newTeamID)
end
- Forboding Angel
- Evolution RTS Developer
- Posts: 14673
- Joined: 17 Nov 2005, 02:43
Re: [suggestion][idea][request][annoyingtag] Supply Cap
Never played AOE but I imagine it's probably pretty similar.
Basically the way it works is that you have a max supply cap amount (in sc, it would be 200). Each mobile unit eats some supply (a variable amount, E.G. Stalker 2, Marine 1, Colossus 6, Skillray 3, etc) and buildings require none.
Basically the way it works is that you have a max supply cap amount (in sc, it would be 200). Each mobile unit eats some supply (a variable amount, E.G. Stalker 2, Marine 1, Colossus 6, Skillray 3, etc) and buildings require none.
-
- Moderator
- Posts: 2464
- Joined: 12 Oct 2007, 09:24
Re: [suggestion][idea][request][annoyingtag] Supply Cap
To put it on the UI just use a teamRulesParam (is that a thing? I know that there is a version for unit and for game) and then make chili read it.
I don't see the difficulty. This is just AllowUnitCreation attached to a counter to keep track of creation and destruction. This should just skip over units in factory queues that take up too much supply cap.
I don't see the difficulty. This is just AllowUnitCreation attached to a counter to keep track of creation and destruction. This should just skip over units in factory queues that take up too much supply cap.
-
- Posts: 1398
- Joined: 17 Sep 2008, 04:36
Re: [suggestion][idea][request][annoyingtag] Supply Cap
AoE was similar but worse. Everything was one supply; supply structures only existed for the sake of supply (whereas ovies, pylons, and depots interact with the game through additional mechanics).
Re: [suggestion][idea][request][annoyingtag] Supply Cap
I liked how the farms in Warcraft 2 were really effective walls. In AoE they just took up space... lot's of space.luckywaldo7 wrote:AoE was similar but worse. Everything was one supply; supply structures only existed for the sake of supply (whereas ovies, pylons, and depots interact with the game through additional mechanics).
- Forboding Angel
- Evolution RTS Developer
- Posts: 14673
- Joined: 17 Nov 2005, 02:43
Re: [suggestion][idea][request][annoyingtag] Supply Cap
Hmm, in evo I was thinking that because storage buildings basically act as capacitors, it would be neat if storage buildings acted as supply givers. In evo storage is really important, but noobs don't understand that, so this would be a way of killing 2 birds with one stone, and overbuilding on supply would be a good thing too because capacitors.
I like unit spamfests as much as the next OTA player, but I also like strategy and tactics involved in army composition.
In evo, using ORBS as nanoturrets, you could essentially have both (meaning that using orbs you can crap out units extremely fast).
Also, supply amounts, by their very nature, have a way of introducing timings, and also introduce another aspect of screwing your enemy. Currently energyscrewing is a valid tactic, supplyscrewing would be another more valid tactic.
So yeah, I have a few pretty legit reasons for wanting this.
ATM I'm out of town on business and can't really do anything till june19th when I get back, but I thought I would get the ball rolling, cause iirc ZK was discussing supply caps as well as a potential gameplay element. Figured that by raising the subject, I kill two birds with one stone and get outside ideas/opinions at the same time.
If no one else has tackled this by then I'll definitely give it a whirl. I think it would do a lot to shape gameplay in a positive light (assuming that implementation into games isn't terrible).
I like unit spamfests as much as the next OTA player, but I also like strategy and tactics involved in army composition.
In evo, using ORBS as nanoturrets, you could essentially have both (meaning that using orbs you can crap out units extremely fast).
Also, supply amounts, by their very nature, have a way of introducing timings, and also introduce another aspect of screwing your enemy. Currently energyscrewing is a valid tactic, supplyscrewing would be another more valid tactic.
So yeah, I have a few pretty legit reasons for wanting this.
ATM I'm out of town on business and can't really do anything till june19th when I get back, but I thought I would get the ball rolling, cause iirc ZK was discussing supply caps as well as a potential gameplay element. Figured that by raising the subject, I kill two birds with one stone and get outside ideas/opinions at the same time.

If no one else has tackled this by then I'll definitely give it a whirl. I think it would do a lot to shape gameplay in a positive light (assuming that implementation into games isn't terrible).
Re: [suggestion][idea][request][annoyingtag] Supply Cap
Flow based economy makes times much more diluted.
- Forboding Angel
- Evolution RTS Developer
- Posts: 14673
- Joined: 17 Nov 2005, 02:43
Re: [suggestion][idea][request][annoyingtag] Supply Cap
Yes, but not irrelevant. Moreover it serves as a meter with which you can measure overall strength.
Re: [suggestion][idea][request][annoyingtag] Supply Cap
IIRC you can do Supply Cap with my tech gadget (with negative ProvideTech and RequireTech).
- Forboding Angel
- Evolution RTS Developer
- Posts: 14673
- Joined: 17 Nov 2005, 02:43
Re: [suggestion][idea][request][annoyingtag] Supply Cap
The negative stuff doesn't work very well in the tech gadget. Tends to be really erratic.
Even so, this should be it's own entity, not something shoehorned into something else.
If for no other reason, Cleanliness.
Even so, this should be it's own entity, not something shoehorned into something else.
If for no other reason, Cleanliness.
-
- Moderator
- Posts: 2464
- Joined: 12 Oct 2007, 09:24
Re: [suggestion][idea][request][annoyingtag] Supply Cap
I think supply on energy storage would be boring on Evo exactly because it kills two birds with one stone. Storage is currently a way of storing up a burst of damage to be unleashed when your armies meet. It can be an interesting choice as to how much you want to spend on increasing the size of your burst damage. If you have a lot of storage it gives your army sustained high damage over some time.
So there is a choice there, storage has a good purpose but there is no prescribed amount you need to make. Maybe you want to play with many small armies attacking at different locations at different times, this would not require much storage to do. On the other hand you may want to make a lot of storage and not much energy if you have a very skirmishy army.
Directly linking army size to storage count removes this choice. By leading people by the hand towards a reasonable way to play you lose diversity. There is no longer a significant storage difference between large armies of different sizes. One will rarely be at an advantage through having much more energy storage. They will both have a minimum baseline.
So there is a choice there, storage has a good purpose but there is no prescribed amount you need to make. Maybe you want to play with many small armies attacking at different locations at different times, this would not require much storage to do. On the other hand you may want to make a lot of storage and not much energy if you have a very skirmishy army.
Directly linking army size to storage count removes this choice. By leading people by the hand towards a reasonable way to play you lose diversity. There is no longer a significant storage difference between large armies of different sizes. One will rarely be at an advantage through having much more energy storage. They will both have a minimum baseline.
- Forboding Angel
- Evolution RTS Developer
- Posts: 14673
- Joined: 17 Nov 2005, 02:43
Re: [suggestion][idea][request][annoyingtag] Supply Cap
Wow. That's actually a really excellent point. Thanks for the insight, I need to think this through so more.
On the one hand it makes it much more noobfriendly (technically?), but on the other hand, the thought of it being a very real choice is very compelling.
Interestingly enough, I also think that a supply cap will have the effect of narrowing the skill gap between vets and newer players.
Maybe not so much that it would make a huge difference, but I like games where the ability of noobs vs vets is more narrow than something like sc2 or even sc. In sc it's all about mechanics and how good you are at real world things like having a high apm with high accuracy, etc etc, multitasking, bla bla. I think that spring games tend to minimize the overall impact of those points.
That said, better mechanics is better mechanics. by default a player with better mechanics will outperform a player with poorer mechanics, but in spring games, due to the way spring works and all our various widget/gadgetry, someone with bad mechanics can very well beat a superior player.
The overall effect being a narrowing of the skill gap between the two types of players.
My description is terrible and crappy, but I'm pretty sure that you understand what I mean.
Let me say it another way... The tools in evo/spring allow me to occasionally beat godde, even though as a player, I am nowhere near as good.
A game that did this very very well (the best I have seen to date, imo) was RUSE. RUSE was all about how you played the game, your strategy and your tactics, as opposed to how fast your could act and how accurate your clicks were (I'm overgeneralizing).
Anyway, I went 50 miles offtopic, but your point is really good, Google.
On the one hand it makes it much more noobfriendly (technically?), but on the other hand, the thought of it being a very real choice is very compelling.
Interestingly enough, I also think that a supply cap will have the effect of narrowing the skill gap between vets and newer players.
Maybe not so much that it would make a huge difference, but I like games where the ability of noobs vs vets is more narrow than something like sc2 or even sc. In sc it's all about mechanics and how good you are at real world things like having a high apm with high accuracy, etc etc, multitasking, bla bla. I think that spring games tend to minimize the overall impact of those points.
That said, better mechanics is better mechanics. by default a player with better mechanics will outperform a player with poorer mechanics, but in spring games, due to the way spring works and all our various widget/gadgetry, someone with bad mechanics can very well beat a superior player.
The overall effect being a narrowing of the skill gap between the two types of players.
My description is terrible and crappy, but I'm pretty sure that you understand what I mean.
Let me say it another way... The tools in evo/spring allow me to occasionally beat godde, even though as a player, I am nowhere near as good.

A game that did this very very well (the best I have seen to date, imo) was RUSE. RUSE was all about how you played the game, your strategy and your tactics, as opposed to how fast your could act and how accurate your clicks were (I'm overgeneralizing).
Anyway, I went 50 miles offtopic, but your point is really good, Google.
Re: [suggestion][idea][request][annoyingtag] Supply Cap
I doubt that is because of the tools in evo/spring. The "tools" of zK only differ in details (custom formation widget and such are the same) so if this was true, you would also be able to occasionally beat godde in zK.Forboding Angel wrote:Let me say it another way... The tools in evo/spring allow me to occasionally beat godde, even though as a player, I am nowhere near as good.![]()
I assume that this would not happen.
-
- Moderator
- Posts: 2464
- Joined: 12 Oct 2007, 09:24
Re: [suggestion][idea][request][annoyingtag] Supply Cap
Storage with supply cap would narrow the skill range with respect to strategic skill. This in some way makes mechanical skill even more important because there is less to gain through strategy. As in if you make your game strategically simpler you lower the strategic skill ceiling so the mechanics become much more important sooner.
This is not to say that supply is bad idea. It might work out well on some dedicated supply structure. This would encourage people to use their armies more quickly. With the state of play as it is I think defences should require supply as well. Be careful with adding these mechanics though, if supply is too cheap then you've just added an attention task. This will only increase the number of tasks you have to do to keep up. So my advice is that if you add a supply building make it expensive enough to be important.
This is not to say that supply is bad idea. It might work out well on some dedicated supply structure. This would encourage people to use their armies more quickly. With the state of play as it is I think defences should require supply as well. Be careful with adding these mechanics though, if supply is too cheap then you've just added an attention task. This will only increase the number of tasks you have to do to keep up. So my advice is that if you add a supply building make it expensive enough to be important.