This is the official forum for the free, fan-made Age of Empires III modification, Wars of Liberty.

Welcome to the New Forum

We hope you enjoy the official new forum of the Wars of Liberty mod for Age of Empires III! Visit this thread to get acquainted with the new forum, and let us know if there's anything we can fix. Feel free to dismiss this message at any time by clicking the "X" in the top right corner.

Thanks!
The Wars of Liberty Team

Forum rules

  • Welcome to The Library! This forum is for asking questions about modding, and sharing maps, mods, and other creations.
  • The official language in this forum is English.
  • Be nice to other members, don't spam comments or smilies, and don't do anything illegal.
  • Posts that don't fit this forum will be moved or deleted.
 
User avatar
Militem Fides
Topic Author
Volunteer
Volunteer
Posts: 113
Joined: Fri Apr 14, 2017 1:37 pm
Location: Brazil
Favorite Civilization: Italians

How to create a new tag for units?

Thu Dec 06, 2018 12:29 pm

Hello,
I would like to ask if it is possible to create a new tag so that instead of listing many units in a technology, I can tie them all in a tag so the technology can affect them.
For example: for pikeman-type units, the AbstractPikeman tag already exists.
I'd like to create something similar for skirmisher units.
"In nomine Domini"
"Ad Majorem Dei Gloriam"
"Um Deus, um rei, uma fé, uma lei"
 
User avatar
AlistairJah
Wars of Liberty Team
Wars of Liberty Team
Posts: 640
Joined: Wed Sep 06, 2017 10:10 am
Location: Madagascar
Favorite Civilization: Bulgarians
Contact:

Re: How to create a new tag for units?

Mon Dec 10, 2018 8:58 am

Nah that's not possible (yet). I think I already explained it in Private Message...
Mis band dondrna b at fa so gaga oe ts maay angle lery
 
User avatar
Militem Fides
Topic Author
Volunteer
Volunteer
Posts: 113
Joined: Fri Apr 14, 2017 1:37 pm
Location: Brazil
Favorite Civilization: Italians

Re: How to create a new tag for units?

Tue Dec 11, 2018 11:37 am

I'm sorry my dear, but I have not received the Message yet. I do not know if maybe it's my account that's crashing ...
"In nomine Domini"
"Ad Majorem Dei Gloriam"
"Um Deus, um rei, uma fé, uma lei"
 
User avatar
Rampo
Parrot
Parrot
Posts: 610
Joined: Sun Jul 02, 2017 2:33 pm
Location: Vung Tau City, Vietnam
Steam: BG_Rampo

Re: How to create a new tag for units?

Sat Mar 02, 2019 2:23 pm

AlistairJah wrote: Nah that's not possible (yet).
AlistairJah, wrong answer....
Militem Fides, sorry for not answering this post to you soons, create unit new tags take multiple check for me. Yes, you can do that
-> many times ago, i'm playing an abanoned but interesting aoe3 mod, i detected that every skirmisher unit has a new tag, "AbstractJunk" and every musket armed heavy infantry unit has a new tag "AbstractPig", creating new unit tag has advantage: it will optimize the xml code for effect unit, specially techtree xml file. i take the arsenal tech: Rifling, as example:
+ Normal XML Code (Using unit effect boost):
<Tech name ='Rifling' type ='Normal'>
<DBID>130</DBID>
<DisplayNameID>23341</DisplayNameID>
<Cost resourcetype ='Wood'>200.0000</Cost>
<Cost resourcetype ='Gold'>200.0000</Cost>
<ResearchPoints>30.0000</ResearchPoints>
<Status>UNOBTAINABLE</Status>
<Icon>ui\techs\rifling\rifling</Icon>
<RolloverTextID>23340</RolloverTextID>
<Flag>UpgradeTech</Flag>
<Flag>CountsTowardMilitaryScore</Flag>
<Prereqs>
<TechStatus status ='Active'>Colonialize</TechStatus></Prereqs>
<Effects>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>Skirmisher</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>Cacadore</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>NatRifleman</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>MercJaeger</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>Strelet</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>NatTracker</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>AbusGun</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>xpMusketWarrior</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>xpWarRifle</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>NatKlamathRifleman</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>NatNavajoRifleman</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>NatMercTracker</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>NatMercRifleman</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>NatMercNavajoRifleman</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>WOTTANatGuaraniRifleman</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>WOTTANatMercGuaraniRifleman</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>GreenJacket</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>Grenzer</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>WOLTxapelgorris</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>WOLJaeger</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>WOLForcePublique</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>WOLAlpino</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>AfricanAskari</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>RifleTroop</Target></Effect>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>DLCCacciatoreMaltese</Target></Effect>
</Effects>
</Tech>

+ Optimized XML code (Use new unit tag boost, for this tech, is AbstractJunk): 
<Tech name ='Rifling' type ='Normal'>
<DBID>130</DBID>
<DisplayNameID>23341</DisplayNameID>
<Cost resourcetype ='Wood'>200.0000</Cost>
<Cost resourcetype ='Gold'>200.0000</Cost>
<ResearchPoints>30.0000</ResearchPoints>
<Status>UNOBTAINABLE</Status>
<Icon>ui\techs\rifling\rifling</Icon>
<RolloverTextID>23340</RolloverTextID>
<Flag>UpgradeTech</Flag>
<Flag>CountsTowardMilitaryScore</Flag>
<Prereqs>
<TechStatus status ='Active'>Colonialize</TechStatus></Prereqs>
<Effects>
<Effect type ='Data' amount ='1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' allactions ='1' relativity ='Absolute'>
<Target type ='ProtoUnit'>AbstractJunk</Target></Effect>
<Effect type ='Data' action ='BuildingAttack' amount ='-1.00' subtype ='DamageBonus' unittype ='AbstractHeavyInfantry' relativity ='Absolute'>
<Target type ='ProtoUnit'>AbstractJunk</Target></Effect>
</Effects>
</Tech>

but creating new unit tag has disadvantage too, when you enable "Show advanced improvement information", the effect information when you point to the tech or hc cards which use new unit tag boost doesn't show, unless you have to do something to make a new coding to show that
to add new unit tag, simply add this:
<UnitType>(New Unit Tag Name)</UnitType>
(New Unit Tag Name): name of unit tag
ESP: Sin amor, el mundo se hundirá en la guerra
POR: Sem amor, o mundo afundará na guerra
ENG: Without love, the world will sink in war

BG Rampo
 
User avatar
AlistairJah
Wars of Liberty Team
Wars of Liberty Team
Posts: 640
Joined: Wed Sep 06, 2017 10:10 am
Location: Madagascar
Favorite Civilization: Bulgarians
Contact:

Re: How to create a new tag for units?

Sat Mar 02, 2019 4:47 pm

I repeat: it is NOT possible to "create new" unit types.
But you can use the unit types that exist.


List of Unit Types
Unit
Ship
Building
MilitaryBuilding
EconomicBuilding
Dropsite
Resource
HuntedResource
MinedResource
LandResource
WaterResource
Projectile
Nature
SpecialPowers
Unattackable
AbstractTemple
Military
Hero
Tree
AbstractInfantry
AbstractCavalry
AbstractArcher
AbstractVillager
AbstractFarm
AbstractDock
InventoryHolder
InventoryItem
UseableItem
StrengthBonus
TradeableTo
TradeableFrom
AbstractSiegeWeapon
FlyingUnit
MythUnit
Economic
Ranged
FastSpeed
AverageSpeed
SlowSpeed
Generic
UnitClass
BuildingClass
NatureClass
EmbellishmentClass
TestClass
E3Class
All
ActionGather
ActionTrain
ActionBuildActionAttack
ActionTrickle
Fish
Transport
AbstractWall
Herdable
AbstractSettlement
BuildingsThatShootMythUnitGodPower
ParticipatesInBattlecries
AffectedByTownBell
MinimapFilterMilitary
MinimapFilterEconomic
TradeUnit
Healable
Fame
RailroadUnit
AbstractRailroadStation
AbstractFort
AbstractImperialArmy
AbstractResourceCrate
AbstractArtillery
AbstractCavalryInfantryAbstractPet
ConvertsHerds
Socket
Aircraft
AbstractLightInfantry
AbstractHeavyCavalry
Huntable
Guardian
AbstractSiegeTrooper
AbstractFirePit
AbstractCanSeeStealth
Mercenary
AbstractWarShip
AbstractLightCavalry
AbstractTradeMarket
AbstractShrine
AbstractWonder
AbstractTypeHuntableMagnet
AbstractTypeHerdableMagnet
AbstractBannerArmy
AbstractMonk
AbstractZamburak
AbstractSepoy
AbstractRajput
AbstractUrumi
AbstractSowarAbstractMahout
AbstractHowdah
AbstractMercFlailiphant
AbstractSiegeElephant
Trade
XP
AbstractDaimyo
AbstractElephant
AbstractCamel
AbstractMilitaryWonder
AbstractPoliticalWonder
AbstractReligiousWonder
AbstractHandElephant
AbstractGurkha
AbstractMansabdar
AbstractChineseMonk
AbstractGunpowderTrooper
AbstractHandInfantry
AbstractHeavyInfantry
AbstractNativeWarrior
AbstractRangedInfantry
AbstractRangedCavalry
AbstractHandCavalry
AbstractGunpowderCavalry
AbstractFishingBoat
GiantBuddha
WaterGuardian
CannotConvertHill
AbstractJapaneseMonk
Gold
AnimalPrey
Food
Wood
FoodDropsite
Hack
WoodDropsiteGoldDropsite
LogicalTypeVillagersRespondToAttack
LogicalTypeHandUnitsAutoAttack
LogicalTypeVillagersAttack
LogicalTypeNeededForVictory
LogicalTypeAffectedByTownBell
NativeBuilding
AbstractHouse
LogicalTypeEasySelectAvoid
ColonyBuilding
LogicalTypeLandMilitary
LogicalTypeNavalMilitary
LogicalTypeGarrisonInShips
AbstractPikeman
AbstractMine
LifespanUnit
TradePostSocket
NativeSocket
HasBountyValue
AbstractLancer
ValidIdleVillager
MercType2
MercType3
MercType4
MercType5
VictoryPointBuilding
LogicalTypeBuildingsNotWalls
LogicalTypeValidSPCUnitsDeadCondition
AbstractTownCenter
LogicalTypeTCBuildLimit
CountsTowardEconomicScore
CountsTowardMilitaryScore
LogicalTypeRangedUnitsAttack
LogicalTypeRangedUnitsAutoAttack
LogicalTypeHandUnitsAttack
LogicalTypeValidSharpshoot
AbstractFruit
AbstractNugget
MercType1
LogicalTypeMinimapFilterEconomic
LogicalTypeMinimapFilterMilitaryLogicalTypeScout
LogicalTypeShipsAndBuildings
LogicalTypeHealed
AbstractWagon
AbstractWhale
AbstractFish
AbstractHandSiege
AbstractIndianMonk
AbstractJunk
AbstractConsulateUnit
AbstractConsulateSiegeFortress
AbstractConsulateSiegeIndustrial
AbstractAgraFortAbstractWokou
AbstractIrregular
AbstractCaptureable
AbstractBarracks2
AbstractStables
AbstractFoundry
Water
AbstractConsulateUnitColonialAbstractCoyoteMan
AbstractNuggetLand
AbstractNuggetWater
LogicalTypeValidSabotage
AbstractPig
LogicalTypeBuildingsNotWallsOrGroves


As you can see, AbstractJunk and AbstractPig are not created. They already existed before.



NOTE: to get the list of Unit Types, enable developer options in gamey.cfg and enable AI debugger as well as AI script compilation logger. After a skirmish, the list will be generated in a dmp file in My games\Wars of Liberty\AI3.
Mis band dondrna b at fa so gaga oe ts maay angle lery
 
User avatar
Rampo
Parrot
Parrot
Posts: 610
Joined: Sun Jul 02, 2017 2:33 pm
Location: Vung Tau City, Vietnam
Steam: BG_Rampo

Re: How to create a new tag for units?

Sun Mar 03, 2019 2:14 am

AlistairJahif my abandoned mod here can do that, why not for wol mod?, i'm sure you haven't played my abandoned mod before. this is the reason why i force to stop playing this wol mod forever
ESP: Sin amor, el mundo se hundirá en la guerra
POR: Sem amor, o mundo afundará na guerra
ENG: Without love, the world will sink in war

BG Rampo
 
User avatar
AlistairJah
Wars of Liberty Team
Wars of Liberty Team
Posts: 640
Joined: Wed Sep 06, 2017 10:10 am
Location: Madagascar
Favorite Civilization: Bulgarians
Contact:

Re: How to create a new tag for units?

Sun Mar 03, 2019 6:12 am

Okay, someone please test this.

No, I'll test it myself. Perhaps all old and experienced modders are wrong after all.
Mis band dondrna b at fa so gaga oe ts maay angle lery
 
User avatar
AlistairJah
Wars of Liberty Team
Wars of Liberty Team
Posts: 640
Joined: Wed Sep 06, 2017 10:10 am
Location: Madagascar
Favorite Civilization: Bulgarians
Contact:

Re: How to create a new tag for units?

Sun Mar 03, 2019 6:30 am

AlistairJah wrote:
Sun Mar 03, 2019 6:12 am
Okay, someone please test this.

No, I'll test it myself. Perhaps all old and experienced modders are wrong after all.
Update: I tested it myself and I confirm that it's NOT possible to create new Unit Types.

Rampo, make a video and show how you "created new unit types".
Mis band dondrna b at fa so gaga oe ts maay angle lery
 
User avatar
Rampo
Parrot
Parrot
Posts: 610
Joined: Sun Jul 02, 2017 2:33 pm
Location: Vung Tau City, Vietnam
Steam: BG_Rampo

Re: How to create a new tag for units?

Sun Mar 03, 2019 9:51 am

AlistairJah, you have to find it at your own, i just discover that. not create that. looks like i treat you as untrusted member here, along with other WOL team members
ESP: Sin amor, el mundo se hundirá en la guerra
POR: Sem amor, o mundo afundará na guerra
ENG: Without love, the world will sink in war

BG Rampo
 
User avatar
AlistairJah
Wars of Liberty Team
Wars of Liberty Team
Posts: 640
Joined: Wed Sep 06, 2017 10:10 am
Location: Madagascar
Favorite Civilization: Bulgarians
Contact:

Re: How to create a new tag for units?

Sun Mar 03, 2019 12:15 pm

Oh... So this is a lie:
Rampo wrote: to add new unit tag, simply add this:
<UnitType>(New Unit Tag Name)</UnitType>
(New Unit Tag Name): name of unit tag

Thank you for trolling, Rampo.
Mis band dondrna b at fa so gaga oe ts maay angle lery

Who is online

Users browsing this forum: No registered users and 1 guest