Battle Points economy for super weapons
- This system displayes a new currency to be used (optionally) in Super Weapons.
- The new currency will be modified by the kills against other players and the system is enabled.
- If set
BattlePointsCollectorin any structure then the system will be enabled if the structure is built. - If set
BattlePointsin houses they will have the system enabled by default. - If set [General] ->
BattlePointsenables/disables the system for every player in the scenario, overriding the country preferences &BattlePointsCollectorsetting. - If set [General] ->
BattlePoints.DefaultValueand the enemy destroyed object doesn't have a value then this generic value will be used instead. - If set [General] ->
BattlePoints.DefaultFriendlyValueand the friendly destroyed object doesn't have a value then this generic value will be used instead. This tag doesn't work with the own objects of the player. - If is set
BattlePoints.CanUseStandardPointsand the destroyed object doesn't have theBattlePointsvalue then the points are obtained from thePointstag of the destroyed object. IfBattlePoints.DefaultValueis present then this will be ignored. - If set
BattlePointsin the destroyed object the calculation is made with this value. Self-Kills done by the own player doesn't count in this system. - If
BattlePoints.Amountis set with a value different from0then the super weapon is influenced by this system. If the value is positive then this super weapon won't be launched until the affected player gathered the required ammount.
In uimd.ini:
[Sidebar]
BattlePointsSidebar.Label=<none> ; CSF entry key `★ <VALUE>`, code U+2605
BattlePointsSidebar.Label.InvertPosition=false ; bool, `<VALUE> ★`, code U+2605
[ToolTips]
BattlePoints.Label=<none> ; CSF entry key, default to `★: <VALUE>`, code U+2605
In rulesmd.ini:
[General]
BattlePoints= ; bool
BattlePoints.DefaultValue= ; int
BattlePoints.DefaultFriendlyValue= ; int
[SOMESIDE] ; Side
Sidebar.BattlePoints.Offset=0,0 ; X,Y, pixels relative to default
Sidebar.BattlePoints.Color= ; integer - R,G,B
Sidebar.BattlePoints.Align=Left ; Left, Right, Center/Centre
[SOMECOUNTRY] ; HouseType
BattlePoints=false ; bool
BattlePoints.CanUseStandardPoints=false ; bool
[SOMEBUILDING] ; BuildingType
BattlePointsGenerator= ; bool
[SOMETECHNO] ; TechnoType
BattlePoints= ; int
[SOMESW]
BattlePoints.Amount=0 ; int
Tested in online and AI respect the points requisite.
I painted this symbol for the code U+2605 for the test in the game.fnt file:
Nightly build for this pull request:
- compiled-dll-c8df88ba680955bfdfba5c0cbec6ef5aaa17dd12.zip These artifacts will expire in 90 days and will not be available for download after that time.
This comment is automatic and is meant to allow guests to get latest nightly builds for this pull request without registering. It is updated on every successful build.
Renamed tag from BattlePointsGenerator to BattlePointsCollector and updated docs and first message
It would be best if it could optionally display a FlyingString when obtaining BattlePoints, just like the bounty of Ares.
It would be best if it could optionally display a FlyingString when obtaining BattlePoints, just like the bounty of Ares.
I prefer keeping the base foundation of the feature simple for a faster merge and in new PRs adding other features (or let other devs to develop them), like:
- Oil Derrick style for generating points overtime.
- Points in crates
- Map Events/Actions for checking & manipulating values.
- Support for non-SW (structures & units like if it was "money")
- Flying strings as you suggested
- ...
These 2 tags are not working:
BattlePointsCollector=true BattlePointsGenerator=true
Is not working for me at the Techno level (building), can only get it to work at [General] with BattlePoints=true, the documentation states otherwise that you can enable this system with a building instead - can you please confirm. Side also does not work with BattlePoints=true
I just tested now in my mod and it works.
With default settings, if you want a structure that enables the logic just put in teh structure: BattlePointsCollector=yes
As soon as it is built your value indicator appears in the sidebar. AAAAAAAND, by default you get no points, unlike Ares bounty logic that forces you to put the value in all objects here just put a default value in: [General] BattlePoints.DefaultValue= ; int And done (if you wanted it a bit simple for testing purposes) For example 100: [General] BattlePoints.DefaultValue=100
So the counter will appear and enable the count after new kills (+100 each enemy kill) when the structure is built. If the collector structure is sold or destroyed the counter dissappears from the sidebar (and resumed the counter) when built again.
If you want it always enabled in a specific house istead of waiting to build a structure then: [SOMECOUNTRY] BattlePoints=true
With my mod settings (when the collector is built the system is enabled): https://github.com/user-attachments/assets/f7148390-a727-41b6-9bfc-b07497f48740
What I missed is the updated documentation here in the first post so I'll update because it isn't called generator, now is collector
Increase the rank of this PR to T3, since the essential of this is about adding a 'secondary resource' to the game, which need careful design for its functionality, interaction with various things and method of implementation first. We could indeed merge this PR first, but a rough structure of its future development needs to be decided I think. Hope @Metadorius and others could give some thought about it
@FS-21 can you try and outline a base for new potential new resource system? perhaps introduce something like CustomResourceType which would have the icon definable and work from that?
For now I propose to first make a mockup of how that would work in INI, and only after that implement it in code.
I already posted what is missing for a full resource support (ignoring the use of the resource for repairing things because is something that could hurt my head if I try to investigate).
First I would like to fix the bug regarding the WH thresholds posted few days ago before I could start thinking in how should be designed in INI
If there is a new currency then why not set this currency to buy some special units?
If there is a new currency then why not set this currency to buy some special units?
Because isn't supported yet and it was planned for Super Weapons not technos.
I was asked to re-make it into a generic system of new resources (like in warcraft or Age of Empires) but until I start that thing this is for now for Super Weapons.
If there is a new currency then why not set this currency to buy some special units?
Because isn't supported yet and it was planned for Super Weapons not technos.
I was asked to re-make it into a generic system of new resources (like in warcraft or Age of Empires) but until I start that thing this is for now for Super Weapons.
hope it will be used for technos too in the future...