mirror of
https://github.com/yairm210/Unciv.git
synced 2025-09-27 05:46:43 -04:00
Added the amphibious promotion and the marine unit (#3987)
* Technology and construction bars no longer extend past their maximum * Fixed compile errors * actually fixed the issue * Added the marine unit * Moved amphibious promotion effect to unique * Added icons for Amphibious promotion and Marine unit * aaah
This commit is contained in:
parent
97a36c3772
commit
432e937474
BIN
android/Images/UnitPromotionIcons/Amphibious.png
Normal file
BIN
android/Images/UnitPromotionIcons/Amphibious.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.3 KiB |
BIN
android/ImagesToPackSeparately/UnitIcons/Marine.png
Normal file
BIN
android/ImagesToPackSeparately/UnitIcons/Marine.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.2 KiB |
@ -410,72 +410,79 @@ Maori Warrior
|
|||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Mechanized Infantry
|
Marine
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1124, 206
|
xy: 1124, 206
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Minuteman
|
Mechanized Infantry
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1226, 308
|
xy: 1226, 308
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Modern Armor
|
Minuteman
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1328, 410
|
xy: 1328, 410
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Mohawk Warrior
|
Modern Armor
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1124, 104
|
xy: 1124, 104
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Musketeer
|
Mohawk Warrior
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1124, 2
|
xy: 1124, 2
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
|
Musketeer
|
||||||
|
rotate: false
|
||||||
|
xy: 1226, 206
|
||||||
|
size: 100, 100
|
||||||
|
orig: 100, 100
|
||||||
|
offset: 0, 0
|
||||||
|
index: -1
|
||||||
Musketman
|
Musketman
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1226, 207
|
xy: 1328, 309
|
||||||
size: 100, 99
|
size: 100, 99
|
||||||
orig: 100, 99
|
orig: 100, 99
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Naresuan's Elephant
|
Naresuan's Elephant
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1328, 308
|
xy: 1430, 410
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Norwegian Ski Infantry
|
Norwegian Ski Infantry
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1430, 410
|
xy: 1226, 104
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Nuclear Missile
|
Nuclear Missile
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1226, 105
|
xy: 1226, 2
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Panzer
|
Panzer
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1328, 206
|
xy: 1328, 207
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
@ -496,126 +503,126 @@ Pikeman
|
|||||||
index: -1
|
index: -1
|
||||||
Rifleman
|
Rifleman
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1226, 3
|
xy: 1328, 105
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Rocket Artillery
|
Rocket Artillery
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1328, 104
|
xy: 1430, 206
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Samurai
|
Samurai
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1328, 2
|
xy: 1532, 308
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Scout
|
Scout
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1430, 206
|
xy: 1634, 410
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Settler
|
Settler
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1532, 308
|
xy: 1328, 3
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Ship of the Line
|
Ship of the Line
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1634, 410
|
xy: 1430, 104
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Sipahi
|
Sipahi
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1430, 104
|
xy: 1430, 2
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Slinger
|
Slinger
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1430, 2
|
xy: 1532, 206
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Spearman
|
Spearman
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1532, 206
|
xy: 1634, 308
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Stealth Bomber
|
Stealth Bomber
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1634, 308
|
xy: 1736, 410
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Submarine
|
Submarine
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1736, 410
|
xy: 1532, 104
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Swordsman
|
Swordsman
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1532, 104
|
xy: 1532, 2
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Tank
|
Tank
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1532, 2
|
xy: 1634, 206
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Tercio
|
Tercio
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1634, 206
|
xy: 1736, 308
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Trebuchet
|
Trebuchet
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1736, 308
|
xy: 1838, 410
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Triplane
|
Triplane
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1838, 410
|
xy: 1634, 104
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Trireme
|
Trireme
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1634, 103
|
xy: 1736, 205
|
||||||
size: 100, 101
|
size: 100, 101
|
||||||
orig: 100, 101
|
orig: 100, 101
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Turtle Ship
|
Turtle Ship
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1736, 206
|
xy: 1634, 2
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
@ -636,28 +643,28 @@ War Elephant
|
|||||||
index: -1
|
index: -1
|
||||||
Warrior
|
Warrior
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1736, 104
|
xy: 1736, 103
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Work Boats
|
Work Boats
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1736, 2
|
xy: 1838, 206
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Worker
|
Worker
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1838, 206
|
xy: 1940, 308
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
index: -1
|
index: -1
|
||||||
Zero
|
Zero
|
||||||
rotate: false
|
rotate: false
|
||||||
xy: 1940, 308
|
xy: 1838, 104
|
||||||
size: 100, 100
|
size: 100, 100
|
||||||
orig: 100, 100
|
orig: 100, 100
|
||||||
offset: 0, 0
|
offset: 0, 0
|
||||||
|
Binary file not shown.
Before Width: | Height: | Size: 278 KiB After Width: | Height: | Size: 279 KiB |
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Before Width: | Height: | Size: 964 KiB After Width: | Height: | Size: 956 KiB |
@ -527,7 +527,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "Nuclear Fission",
|
"name": "Nuclear Fission",
|
||||||
"row": 3,
|
"row": 4,
|
||||||
"prerequisites": ["Atomic Theory","Radar"],
|
"prerequisites": ["Atomic Theory","Radar"],
|
||||||
"quote": "'I am become Death, the destroyer of worlds.' - J. Robert Oppenheimer"
|
"quote": "'I am become Death, the destroyer of worlds.' - J. Robert Oppenheimer"
|
||||||
},
|
},
|
||||||
|
@ -135,6 +135,12 @@
|
|||||||
"effect": "Double movement rate through Forest and Jungle",
|
"effect": "Double movement rate through Forest and Jungle",
|
||||||
"unitTypes": ["Melee"]
|
"unitTypes": ["Melee"]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "Amphibious",
|
||||||
|
"prerequisites": ["Shock I", "Drill I"],
|
||||||
|
"uniques": ["Eliminates combat penalty for attacking over a river", "Eliminates combat penalty for attacking from the sea"],
|
||||||
|
"unitTypes": ["Melee"]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "Medic",
|
"name": "Medic",
|
||||||
"prerequisites": ["Shock I", "Drill I", "Scouting II"],
|
"prerequisites": ["Shock I", "Drill I", "Scouting II"],
|
||||||
|
@ -525,7 +525,7 @@
|
|||||||
"upgradesTo": "Musketman",
|
"upgradesTo": "Musketman",
|
||||||
"obsoleteTech": "Metallurgy",
|
"obsoleteTech": "Metallurgy",
|
||||||
"requiredResource": "Iron",
|
"requiredResource": "Iron",
|
||||||
"uniques": ["Amphibious"],
|
"promotions": ["Amphibious"],
|
||||||
"hurryCostModifier": 20,
|
"hurryCostModifier": 20,
|
||||||
"attackSound": "metalhit"
|
"attackSound": "metalhit"
|
||||||
//Danish unique unit. Can attack from the sea without any penalty, and moves faster.
|
//Danish unique unit. Can attack from the sea without any penalty, and moves faster.
|
||||||
@ -1175,6 +1175,17 @@
|
|||||||
"obsoleteTech": "Mobile Tactics",
|
"obsoleteTech": "Mobile Tactics",
|
||||||
"attackSound": "shot"
|
"attackSound": "shot"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "Marine",
|
||||||
|
"unitType": "Melee",
|
||||||
|
"movement": 2,
|
||||||
|
"strength": 65,
|
||||||
|
"cost": 400,
|
||||||
|
"requiredTech": "Pharmaceuticals",
|
||||||
|
"attackSound": "shot",
|
||||||
|
"promotions": ["Amphibious"],
|
||||||
|
"uniques": ["+1 sight when embarked", "Defense bonus when embarked"]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "Machine Gun",
|
"name": "Machine Gun",
|
||||||
"unitType": "Ranged",
|
"unitType": "Ranged",
|
||||||
|
@ -118,9 +118,10 @@ object BattleDamage {
|
|||||||
modifiers.add("Attacker Bonus", unique.params[0].toInt())
|
modifiers.add("Attacker Bonus", unique.params[0].toInt())
|
||||||
}
|
}
|
||||||
|
|
||||||
if (attacker.unit.isEmbarked() && !attacker.unit.hasUnique("Amphibious"))
|
if (attacker.unit.isEmbarked() && !attacker.unit.hasUnique("Eliminates combat penalty for attacking from the sea"))
|
||||||
modifiers["Landing"] = -50
|
modifiers["Landing"] = -50
|
||||||
|
|
||||||
|
|
||||||
if (attacker.isMelee()) {
|
if (attacker.isMelee()) {
|
||||||
val numberOfAttackersSurroundingDefender = defender.getTile().neighbors.count {
|
val numberOfAttackersSurroundingDefender = defender.getTile().neighbors.count {
|
||||||
it.militaryUnit != null
|
it.militaryUnit != null
|
||||||
@ -130,7 +131,7 @@ object BattleDamage {
|
|||||||
if (numberOfAttackersSurroundingDefender > 1)
|
if (numberOfAttackersSurroundingDefender > 1)
|
||||||
modifiers["Flanking"] = 10 * (numberOfAttackersSurroundingDefender - 1) //https://www.carlsguides.com/strategy/civilization5/war/combatbonuses.php
|
modifiers["Flanking"] = 10 * (numberOfAttackersSurroundingDefender - 1) //https://www.carlsguides.com/strategy/civilization5/war/combatbonuses.php
|
||||||
if (attacker.getTile().aerialDistanceTo(defender.getTile()) == 1 && attacker.getTile().isConnectedByRiver(defender.getTile())
|
if (attacker.getTile().aerialDistanceTo(defender.getTile()) == 1 && attacker.getTile().isConnectedByRiver(defender.getTile())
|
||||||
&& !attacker.unit.hasUnique("Amphibious")) {
|
&& !attacker.unit.hasUnique("Eliminates combat penalty for attacking over a river")) {
|
||||||
if (!attacker.getTile().hasConnection(attacker.getCivInfo()) // meaning, the tiles are not road-connected for this civ
|
if (!attacker.getTile().hasConnection(attacker.getCivInfo()) // meaning, the tiles are not road-connected for this civ
|
||||||
|| !defender.getTile().hasConnection(attacker.getCivInfo())
|
|| !defender.getTile().hasConnection(attacker.getCivInfo())
|
||||||
|| !attacker.getCivInfo().tech.roadsConnectAcrossRivers) {
|
|| !attacker.getCivInfo().tech.roadsConnectAcrossRivers) {
|
||||||
|
@ -103,6 +103,7 @@ Unless otherwise specified, all the following are from [the Noun Project](https:
|
|||||||
* [Manhattan Project](https://thenounproject.com/search/?q=Nuclear%20Bomb&i=2041074) By corpus delicti, GR
|
* [Manhattan Project](https://thenounproject.com/search/?q=Nuclear%20Bomb&i=2041074) By corpus delicti, GR
|
||||||
* [Nuclear Missile](https://thenounproject.com/marialuisa.iborra/collection/missiles-bombs/?i=1022574) By Lluisa Iborra, ES
|
* [Nuclear Missile](https://thenounproject.com/marialuisa.iborra/collection/missiles-bombs/?i=1022574) By Lluisa Iborra, ES
|
||||||
* Icon for Carrier made by [JackRainy](https://github.com/JackRainy), based on [Aircraft Carrier](https://thenounproject.com/icolabs/collection/flat-icons-transport/?i=2332914) By IcoLabs, BR
|
* Icon for Carrier made by [JackRainy](https://github.com/JackRainy), based on [Aircraft Carrier](https://thenounproject.com/icolabs/collection/flat-icons-transport/?i=2332914) By IcoLabs, BR
|
||||||
|
* [Water Gun](https://thenounproject.com/term/water-gun/2121571) by ProSymbols for Marine
|
||||||
|
|
||||||
### Great People
|
### Great People
|
||||||
|
|
||||||
@ -501,6 +502,7 @@ Unless otherwise specified, all the following are from [the Noun Project](https:
|
|||||||
* Icon for Flight Deck is made by [JackRainy](https://github.com/JackRainy)
|
* Icon for Flight Deck is made by [JackRainy](https://github.com/JackRainy)
|
||||||
* Icon for Armor Plating is made by [JackRainy](https://github.com/JackRainy)
|
* Icon for Armor Plating is made by [JackRainy](https://github.com/JackRainy)
|
||||||
* [Slingshot](https://thenounproject.com/term/slingshot/9106/) by James Keuning for Slinger Withdraw
|
* [Slingshot](https://thenounproject.com/term/slingshot/9106/) by James Keuning for Slinger Withdraw
|
||||||
|
* [Anchor](https://thenounproject.com/term/anchor/676586) by Gregor Cresnar for Amphibious
|
||||||
|
|
||||||
## Others
|
## Others
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user