-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Modding requests #3242
Comments
When described in the json, roads and railroads could have parameters like "Double movement rate" and "Triple movement rate upon researching [ ]". There's lots of opportunity here.
A unique for this, maybe "Is removed by [Remove Forest]".
"Can construct [Road], [Fort]".
Maybe a "UniquetoUnit" parameter inside the "uniques": in TileImprovents.json or something similar? This would also allow Oil Wells to be restricted to Workers and Offshore Platforms to be restricted to Work Boats, as in Civ 5, assuming that the "improvement": parameter in TileResources.json can handle more than one improvement. |
A unique to the effect of "Must be on [River]" or something similar would be great, especially for futureproofing Unciv for Civ 6 (if you eber get to that), and also for modding. |
Here are some ideas for uniques. "Can not be sold" - for buildings. "Unlocks at [Era name]" - for buildings and units and improvements (already implemented for Policies). "Food required for population growth +/- [x]%" - as nation and policy unique (also called civ-wide). |
Another suggestions; "Unlocks at [era]" unique for buildings, units; |
This is already mentioned on the first comment but: A unique that allows units to build specific tile improvements, like "Can construct [Fort]". |
A unique that let's you do canals for improvements or tiles. With this, we could make canals (like, suez canal) or make navigable rivers; or even the opposite, as bridges (like the one that ties scotland and ireland). The problem I see with it is that AI would be very dumb to use it but what we care is for the player. |
Any wiki tutorial how to mod m̶u̶s̶i̶c̶ sound? |
A unique for polices that gives you a free policy, but from a specific tree. |
allow tile filter to contain more than one tile f.i allow this to work this is my attempt to only make plain desert tiles get petra bonuses but it completely broke so it gives bonuses to all |
more than 1 techs required for a building |
add a property to improvements that is can be build by [unitFilter] so the mods can add more than 1 types of workers. this however should only be the case for worker units that are able to open up select improvements to build window rather than something like legions that have an ability to build only roads |
This is already implemented the other way around, as you can have the "Can build [improvementFilter] improvements" uniques for units, so this can allow building specific improvements or groups of improvements |
is there a distinction between units than can open up build improvement screen and others? also do you need to do something like this "can build [mine]" "can build [farm] etc or can it directly do can build "[mine,farm,quarry]" etc. |
Only units that have have the "Can build []" unique can open the "build improvement"-screen. Uniques don't support comma separation, so you need a different unique for each imrpovement |
comma seperation for uniques |
two uniquesets for anything that supports uniques, one for with religion on and one with religion off like: or we can just make the game ignore anything about faith or gprop points when religion is disabled |
being able to put decimals in bonuses for instance. [+0.50 Food] for [tundra] tiles for each adjacent [mountain] tiles [in all cities] for instance when calculating this you do math on each other and remove the decimal at the end of the calculation (or just allow decimals in [stats]) |
add an option to hide certain uniques from showing up in descriptions like something something: |
Use the |
Try adding "This unit loses the [promotion] promotion <for [non-[civName]]>" to the added promotion? Or another promotion that's also added to that unit? |
Oh wow that's very meta and a trick I'll remeber for the future :D |
Oh. Double movement is also unit-only. I can add yet another promotion bound to nation, but maybe it's worth it to allow nation-wide modification here as well? |
Echoing LoliAkulka's suggestion over on Discord - a <if [modFilter] is enabled> conditional would be great. |
Damn, that's meta :| |
We don't have one already? Then I probably dreamed about it long ago then forgot on waking up... Any volunteers to test this patch?Subject: [PATCH] Extend docDescription
---
Index: core/src/com/unciv/models/ruleset/validation/ModCompatibility.kt
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/core/src/com/unciv/models/ruleset/validation/ModCompatibility.kt b/core/src/com/unciv/models/ruleset/validation/ModCompatibility.kt
--- a/core/src/com/unciv/models/ruleset/validation/ModCompatibility.kt (revision bcf50497ab68d9d82263e8f99862aa7d42268142)
+++ b/core/src/com/unciv/models/ruleset/validation/ModCompatibility.kt (date 1719508388471)
@@ -56,7 +56,7 @@
&& mod.name.isNotBlank()
&& !mod.modOptions.hasUnique(UniqueType.ModIsAudioVisualOnly)
- private fun modNameFilter(modName: String, filter: String): Boolean {
+ fun modNameFilter(modName: String, filter: String): Boolean {
if (modName == filter) return true
if (filter.length < 3 || !filter.startsWith('*') || !filter.endsWith('*')) return false
val partialName = filter.substring(1, filter.length - 1).lowercase()
Index: core/src/com/unciv/models/ruleset/unique/UniqueType.kt
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/core/src/com/unciv/models/ruleset/unique/UniqueType.kt b/core/src/com/unciv/models/ruleset/unique/UniqueType.kt
--- a/core/src/com/unciv/models/ruleset/unique/UniqueType.kt (revision bcf50497ab68d9d82263e8f99862aa7d42268142)
+++ b/core/src/com/unciv/models/ruleset/unique/UniqueType.kt (date 1722979006393)
@@ -937,6 +937,7 @@
ModIsNotAudioVisual("Cannot be used as permanent audiovisual mod", UniqueTarget.ModOptions, flags = UniqueFlag.setOfNoConditionals),
ModMapPreselection("Mod preselects map [comment]", UniqueTarget.ModOptions, flags = UniqueFlag.setOfNoConditionals,
docDescription = "Only meaningful for Mods containing several maps. When this mod is selected on the new game screen's custom maps mod dropdown, the named map will be selected on the map dropdown. Also disables selection by recently modified. Case insensitive."),
+ ConditionalModEnabled("if [modFilter] is enabled", UniqueTarget.Conditional),
// endregion
Index: core/src/com/unciv/models/ruleset/unique/Conditionals.kt
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/core/src/com/unciv/models/ruleset/unique/Conditionals.kt b/core/src/com/unciv/models/ruleset/unique/Conditionals.kt
--- a/core/src/com/unciv/models/ruleset/unique/Conditionals.kt (revision bcf50497ab68d9d82263e8f99862aa7d42268142)
+++ b/core/src/com/unciv/models/ruleset/unique/Conditionals.kt (date 1722756642467)
@@ -6,6 +6,7 @@
import com.unciv.logic.city.City
import com.unciv.logic.civilization.Civilization
import com.unciv.logic.civilization.managers.ReligionState
+import com.unciv.models.ruleset.validation.ModCompatibility
import com.unciv.models.stats.Stat
import kotlin.random.Random
@@ -303,6 +304,11 @@
first in second..third
}
+ UniqueType.ConditionalModEnabled -> checkOnGameInfo {
+ val filter = conditional.params[0]
+ (gameParameters.mods.asSequence() + gameParameters.baseRuleset).any { ModCompatibility.modNameFilter(it, filter) }
+ }
+
else -> false
}
} Edit for reference: got implemented in 2b81172 |
@SomeTroglodyte Works like a charm :D |
At this point I am convinced that Yairm is an alien and SomeTrog is a sorcerer |
No, one is an alienated sorcerer and the other an ensorcelled alien. |
At least I was somewhat close |
Idea: A debug flag to disable the "Hidden" flags - so one can better analyze a mod using Civilopedia??? Is that clever or just senility speaking? Edit: Code is pretty simple... |
Looks good @SomeTroglodyte seems like a no-brainer to have. Over in adding yet another modding request: I'm reaching for a grey area of movement caching compatibility. If the tile's movement condition was able to be precalc'd under a fixed conditional, that could potentially be non-dynamic as to not interfere with reachability. Fixed conditional example: Requires dynamic consideration example: Fixed conditionals could be labeled in the wiki as fixed conditionals which may go towards guiding the modder on which conditionals may apply. Instead of noting "Due to performance considerations..." if a pre-cached conditional applies, a new statement could be "Compatible with fixed conditionals only". 🥇 🏆 |
...not accurate, mapUnitFilter can include "wounded", "embarked", promotion name (which can be gained within a turn), etc |
k thanks for considering =) |
Well, "Gain control over [all] tiles in a [1]-tile radius" never appears in Unciv Wiki , is it okay? This has been solved in new version. |
I would like to ask for opening alternatives revealing a resource other than tech, such as by policies or beliefs. |
Modding city states to:
all of these as seperate uniques would be great, also give city state types (militaristic, mercantile, etc) the ability to be given uniques if it isn't possible already. |
new UnitActionModifier: <loses [promotion] promotion> |
<upon gifting a [mapUnitFilter] unit to [civFilter]> would be neat to have. Would allow to mod a civ that gains some compensations for gifting units |
UnitFilter:
To be able to award upgrades just as promotions are. |
I am once again requesting some uniques, Unit Trigger Condition Thank you |
I am once again requesting some uniques, I'm sorry but, because of my misunderstanding, I would like to request: And I don't know if it's a valid request but, Thank you! |
|
Annnd requesting the unique |
A bombing run unique would be cool. Applications beyond bombing runs possible including wide-beam attacks. Would require start tile, range, destination tile. Path determined, perhaps shown like <Attack profile Bombing Run with a radius of [Radius]> Possible evo: Random R option; R+1 linear spread option |
I've been thinking for a long time of tile targetted triggers - i.e. special attacks, but the problem is mainly a UI one, and I don't enjoy UI |
There have been a lot of various requests to extend the modding in various ways.
Usually they're from one person, and have very little effect on the general playerbase, and they're kind of clogging up the issues.
So this is an issue to consolidate all those requests, as comments to this issue.
The text was updated successfully, but these errors were encountered: