Game definition jsons - Effect definition json

Learn the .json format
used to define characteristics of units and other game elements
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Game definition jsons - Effect definition json

Post by Stratego (dev) »

Here is how to create effect definitions (that can be used in "spell" or ability section of a unit json)

Below you can find these main sections
* List of attributes
* Possible Values of different tags
- effect behaviours
- possible target types
- system special effects
- Specs
* Summon or Place effect
* FULL TEMPLATE
* Button image appearance
* Extra simplification on images
* TRIGGERED effects


List of attributes(not complete list)
lastsTurnNr: -1 means stays forever, 0..any means lasts that many turns
effectTriggers:
possible events:
- ON_DAMAGED, "single" type : when unit (having this active effect) gets damaged
- ON_DAMAGES, "single" type : when unit (having this active effect) deals damage
- ON_DIED, "single" type : it can be a simple prop changer effect, or a related effect to it that is to be launched
- ON_KILL_ENEMY, "single" type : when unit (having this active effect) kills an enemy
- ON_DAMAGED_AMOUNT, "multiplied" type: triggers same time as ON_DAMAGED
- ON_DAMAGES_AMOUNT "multiplied" type: triggers same time as ON_DAMAGES
"single" type: means the effect will run once and with x * 1 multiplier on eg. prochanger case.
"multiplied" type: means the effect will run as many times as the damage amount (so with =x * damage_amount) multiplier on eg. prochanger case (adds that many hp that many damage it dealt)



effect behaviours:
INSTANT, //SPELL immediate and permanent kind and no long lasting effects
ENCHANTMENT, //EFFECT long lasting modifier, but activates only on the first turn, when removed the modifications are undoed (need to save or something), should not be special ability like convert
ENCHANTMENT_VANISHING, //EFFECT long lasting modifier, but activates only on the first turn, when wears off or removed the modifications are undoed (need to save or something), should not be special ability like convert
INSTANT_REPETITIVE_VANISHING, //EFFECT on impact, and each turn it executes (eg. poisoning), when vanished unit remains as it is (no regaining abilities).
REPETITIVE_VANISHING, //EFFECT on impact does nothing, but each turn it executes (eg. poisoning), when vanished unit remains as it is (no regaining abilities).
REPETITIVE_VANISHING_ENCHANTMENT, //EFFECT on impact does nothing, but each turn it executes (eg. slowing), when vanished unit regains its old abilities
SUSPENDED, //EFFECT does nothing on impact and nothing on countdown, but at the end it executes the effect (eg. delayed conversion), permanent
TRIGGERED_EFFECT, //EFFECT says : no execute, only on trigger.
EFFECT_SPELL, // only places an effect of a different effectID (giving lifelink)
AURA_EFFECT //EFFECT says : no execute, only on AURA TRIGGERS. (an aura)
possible target types:
HIMSELF,
FRIENDLY,
FRIENDLY_BUT_NOT_ME,
ENEMY,
ENEMY_OR_FRIENDLY,
ENEMY_OR_FRIENDLY_BUT_NOT_ME,
Apart from these you can "target" units by setting a "trnActionUnitID" and that will filter out the possible "validTargerts" set in that reference
eg:

Code: Select all

"trnActionUnitID":"EFFECT_NON_STRUCTURE",
note: it is not checked in these cases
- EFFECT_SPELL type: here the placed effect checeked instead
- Transform (as the target unit type can be set in this attribute)
- Summon (as the target unit type can be set in this attribute)
but it is checked on other cases.



special cost options:
SACRIFICE_UNIT, // spell that requires specCostNr number of nearby corpse (consumes it) to be casted
SACRIFICE_UNIT_COST_SUM, //will select the units by their cost - the required amount of turncost is in specCostNr
SACRIFICE_HP_AMOUNT,
SACRIFICE_POWER_AMOUNT,
NEARBY_CORPSE, // spell that requires specCostNr number of nearby corpse (consumes it) to be casted
ACTION_POINT //if set than it requires extra action points or even 0 action point, altering the default 1 action cost

also you specify unit types in trnSpecCostTypeList

system special effects
public static final int SYSTEM_SPECIAL_EFFECT_CONVERT = 100;
public static final int SYSTEM_SPECIAL_EFFECT_HEAL = 101;
public static final int SYSTEM_SPECIAL_EFFECT_DISENCHANT = 102;
public static final int SYSTEM_SPECIAL_EFFECT_SUMMON = 103;
public static final int SYSTEM_SPECIAL_EFFECT_REGENERATION = 104;



public static final int SYSTEM_SPECIAL_EFFECT_FORESTWALK = 108;
public static final int SYSTEM_SPECIAL_EFFECT_MOUNTAINWALK = 109;
public static final int SYSTEM_SPECIAL_EFFECT_WATERWALK = 110;
public static final int SYSTEM_SPECIAL_EFFECT_AIRWALK = 111;

public static final int SYSTEM_SPECIAL_EFFECT_TRANSFORM1 = 112;
public static final int SYSTEM_SPECIAL_EFFECT_ANIMATE_DEAD = 113;

public static final int SYSTEM_SPECIAL_EFFECT_ENVIRONMENTAL = 114; //An instant spell that casts a lightning storm, or fireball storm or ice storm - effects in a radius with a special randomization
public static final int SYSTEM_SPECIAL_EFFECT_DISABLE = 115; //Disables unit: considers unit "disabled" also removes all action point and movement points of a unit, on effect removal re initializes them.

public static final int SYSTEM_SPECIAL_EFFECT_LASTSTURN_MODIFIER = 116; // a spell that will modify the lasts turn nr of one or more running effects (defined in trnAffectedEffectDefs) on target unit
public static final int SYSTEM_SPECIAL_EFFECT_SUMMON_IMMEDIATE = 117;
public static final int SYSTEM_SPECIAL_EFFECT_RELOCATE = 118; // used to "teleport" the caster unit to the target location, target is read by the green environmental floating action.
public static final int SYSTEM_SPECIAL_EFFECT_REVEAL = 119; // used to reveal a spot on target location, target is read by the green environmental floating action.
public static final int SYSTEM_SPECIAL_EFFECT_PROD_SPEEDUP = 120; // production speedup works exactly like the PROD_SPEEDUP specunitaction, will instantly decrease turnsleft (by dataInt value) in production (self sacrifice should be coded in json)
public static final int SYSTEM_SPECIAL_EFFECT_COOLDOWN_MODIFIER = 121; // dataInt must be filled!, a spell that will modify the cooldown of one or more running effects (defined in trnAffectedEffectDefs) on target unit having cooldown
SYSTEM_SPECIAL_EFFECT_TERRAIN_DECORATION_SET = 122; // dataInt must be filled!, dataInt is the DECORATION terrain ID to be placed on the effect execution tile (under the unit, or on target tile) - if 0 than clears the decoration only
SYSTEM_SPECIAL_EFFECT_TARGET_AND_AREA = 123; //like SYSTEM_SPECIAL_EFFECT_ENVIRONMENTAL but used by targeting a unit (not by dragging) and inflicts an area like (fill environmental area settings!)
SYSTEM_SPECIAL_EFFECT_TRANSFORM2 = 124; //[!!!OBSOLETE!!! use SYSTEM_SPECIAL_EFFECT_TRANSFORM_BY_GROUP]secondary transfom, dont use for abilities, executes transform definition, target unit id can ONLY be set on the "carrier" unit of this effect (use for eg. turn unit to this zombie unit)
public static final int SYSTEM_SPECIAL_EFFECT_TRANSFORM_BY_GROUP = 125; ////set the transform name in dataString, executes transform definition, target unit id can ONLY be defined via trnTransformToList. Alternate of SYSTEM_SPECIAL_EFFECT_TRANSFORM1. So a unit can have any number of transformations - each defined in trnTransformToGroups Array. An effect can execute a particular transform from this list.


Specs Other special settings in a list called "specs" you set these in "trnSpecs":
BYPASS_SPELL_RESISTANCE, // set this to make the spell to be an ability that is not reduced by spell resistance at all (update: any resistance)
RESISTED_BY_DODGE_MELEE, // probability is calculated as dodge melee is calculated
RESISTED_BY_DODGE_RANGED, // probability is calculated as dodge ranged is calculated
RESISTED_BY_HP, // probability is calculated based on DEFINE_UNIT_BIG_HP_VALUE and unit hp
RESISTED_BY_POWER, // probability is calculated based on DEFINE_UNIT_BIG_POWER_VALUE and unit hp
IS_NEGATIVE_EFFECT, // set this to make the effect a negative one like slowing (if not set than considered positive like strengthening), now in AOF disenchant uses if it wants to remove effect or not
IS_EFFECT_RANGE_ABSOLUTE, // if set than effect has ablsolute range - independent from caster spell range.
IS_EFFECT_RANGE_IS_RANGE_ATTACK, // uses unit.rangeAttack in the effect instead of ability range (IS_EFFECT_RANGE_ABSOLUTE also usable with it)
IS_COOLDOWN_ON_SPAWN, // if set AND it has cooldown, than the cooldown will start right on unit spawning
IS_COUNTDOWN_ON_SPAWN, // if set AND it has counter set (lastsNr), eg SUSPEND or VANISHING kind, than the counter will start the first count right on unit spawning

IS_TERRAIN_SOURCE, // this effect is from a terrain affection (like in woods foot units can have +1 defense)
NO_AUTOCAST, // this effect must be casted manually by player, must not be casted automatically by playerAI as instinct-action.
NO_AI_CAST, // this effect must not be casted by AI (maybe makes harm as not properly implemented the usage)
WEARS_OFF_AFTER_MOVE, // the effect (if on unit as a enchantment) will wears off after unit moves
WEARS_OFF_AFTER_ATTACK, // the effect (if on unit as a enchantment) will wears off after unit attacs
WEARS_OFF_AFTER_ABILITY_USE, // the effect (if on unit as a enchantment) will wears off after unit uses spell or ability
CAN_TARGET_TC_FIRST, // if set: the spell can target the tc if the first unit is targetable, only that unit will receive the effect
CAN_TARGET_TC_FIRST_TARGETABLE, // if set: the spell can target the tc any of units is targetable, but only first of them will get the effect
CAN_TARGET_INATTACKABLES, // this effect (prop changer) can affect inattackable units too (even if it is a hp decremental one) - eg. Kill unit special effect for vanishing
CAN_CAST_FROM_CARRIER, // if isCarrierLetCarriedUnitsToShoot=false on unit than basically no abilites can run, with this setting unit can use the ability.
CAN_CAST_FROM_ITS_BUILDER, // The effect can only be used inside a factory this unit was/can be built.
CAN_CAST_FROM_ITS_TRANSFORM_BUILDER, // Transform case: The transform effect can only be used inside a factory where the target unit type can be built.
CAN_CAST_INTO_CARRIER, // if set than ignores the building setting if inner units are targetable or not - they will be targetable (eg. handgrenade in AOMW)
CAN_AFFECT_ALL_IN_CARRIER, // if targets a TC or combined with CAN_CAST_INTO_CARRIER the effect can affect all units inside (that is targetable with the effect) (eg. handgrenade in AOMW)
CAN_BE_COUNTER_ATTACKED, // set if this effect can be counterattacked (like normal attacks), eg bombing ability in AOW
UNIQUE_WITHIN_GROUP, // If set it enables checking this: In its group only one can be "sticked" on a unit at the same time (all such effects needs this), do not set on Aura effects, only normal unit targeted sticky spells


AMOUNT_BY_STRENGTH, // if set than the caster unit's strength will mutiply the "effect" (effect will run this many times)
AMOUNT_BY_HP, // if set than the caster unit's hp will mutiply the "effect" (effect will run this many times)
AMOUNT_BY_ABILITY, // in case of non prop.changer effects (eg. multiple enchantments to put): use the effect that many times as the abilityPower of caster unit (use positive integer value!)
CHG_POWER_BY_ABILITY_MULTIPLY, // (beware on stickers** see on end) in case of property changer effect: multiply the effect (the changing numerical values) with abilityPower of caster unit (use positive value!) - **If this spec is used on any sticker effect in chain of related effects - every other sticker related effect have to have it too
CHG_POWER_BY_ABILITY_ADD, // (dont use on stickers!*) in case of property changer effect: add the effect (the changing numerical values) the abilityPower of caster unit (use positive value!)
CHG_POWER_BY_ATTACK_MULTIPLY, // (beware on stickers** see on end) in case of property changer effect: multiply the effect (the changing numerical values) with attackPower of caster unit - **If this spec is used on any sticker effect in chain of related effects - every other sticker related effect have to have it too

IS_AURA_AFFECTS_ONLY_INSIDE, //this aura is only for carriers, and this aura will affect only units inside

SET_TARGETED_UNIT_TYPE_ON_EFFECT_AFFECT, //if set the unit type of the target unit will be stored on its effectAffect object (this exists only on staying-on-taget like effects, eg: enchantments )
ENV_AFFECT_EACH_TILE, //if set then targeting a mega unit (multi tiled) will affect all tiles of the unit (if in range) not only once on the mega building.

RUN_RELATED_EFFECT_FIRST, //default is: running related effects after the normal effect, this option reverses the order

HIDE_BUTTON_IF_NO_SPEC_COST_AVAILABLE, //if set the button will not appear when the spec cost is not available (like riding an unicorn will
available if unicorn nearby)
GFX_USE_UNIT_IMAGE_AS_PROJECTILE, //in AOW the bomber plane's bombing ability should use the plane itself to move over target (like melee attacks do)
* dont use on stickers!*: means dont use this setting on an ability that casts effect to units that "sticks" and should be removed by disenchant, or vanishes in time and so on. (reason: on effect removal unit will not return to its original values) - so buggy
update: checked in cose and "amount" is saved with effect affect so probably undoes can run nicely, so not sure which cases are not permitted here...




Summon or Place effect

Here the effect will spawn an other "unit" on pressing the effect button of the "caster" unit, it will start floating like the elf wolf does.
living samples:
- aof: elf wolf, skeleton dragon + orc dragon etc.
- aow: sea mines
{
"effectNameString":"EFFECT_INSTANT_SUMMON_WOLF", ---------------------- effect name
"effectDefID":126,------------------------------------------------------------------effect id
"trnActionUnitID":"UNIT_GER_BLD_WATER_MINES",------- --------------which unit to summon ("NO_UNIT" means "unset" value)
"trnActionUnitIDForCaster":"NO_UNIT",-----------------------------------------which effect to apply on caster after casting (ef. losing health) ("NO_UNIT" means "unset" value)

"trnButtonTextureID":"TEXTURE_XY",-------------------------------------------for unique button (if the deafult the summoned unit image is not good enough)
"trnActionTextureID":"TEXTURE_XY",---------------------------------------------


"chancePercent":1.0,----------------------------------------------------------------chance of casting the spell, here use 1=100% if you want to be always
// Also on WEAPON_SLOT_1,WEAPON_EFFECT_SLOT_HEAL the probability to take effect on targeted/damaged unit (eg. is weapon fire effect sticks on enemy or not)
"lastsTurnNr":0,-----------------------------------------------------------------------not used here

"effectBehaviour":"INSTANT",--------------------------------------------------------effect behaviour (see above)
"effectTargets":"HIMSELF",-----------------------------------------------------------tagert types (see above)
"trnSystemSpecialEffectID":"SYSTEM_SPECIAL_EFFECT_SUMMON ",-----------Special effects (see above), here this is the summon unit

"trnTransformTo" ----------------------------------------------------------------------transformation ID, used for case of SYSTEM_SPECIAL_EFFECT_TRANSFORM1, if null than the Unit.transformTo1 value will be used


"castRangeModifier":0,---------------------------------------------------------------- it can modify the spell range relative to caster default spellrange (eg +3)
"cooldownTurnNr":0,------------------------------------------------------------------If you want the spell has cooldown (caster needs to wait X turns before casting it again.)

"specCost":null,-------------------------------------------------------------------------special cost type (see above)
"specCostNr":1,--------------------------------------------------------------------------special cost amount (eg. 3 nearby corpses)
"trnSpecCostTypeList":null,------------------------------------------------------------- special cost type listt to be sacrificed: eg you can list only goblins, by category or specify exact types
"trnRequires":null,-----------------------------------------------------------------------required techs to be owned before use this effect

"priority":0-------------------------------------------------------------------------------The priority the AI should use when selecting weapons against targets: 0 for irrelevant ones, about 900 on strongest effects, 100-800 the average effects

}

FULL TEMPLATE: just a full template ------
{
"effectNameString":"EFFECT_INSTANT_SUMMON_WOLF", ---------------------- effect name
"effectDefID":126,------------------------------------------------------------------effect id
"trnEffectDefIDRelated":"EFFECTNAME",------------------------------------------------------------ effevct to place on target
trnEffectDefIDOnFail = "EFFECTNAME"; -------------------------------------------------------- used when the effect casting falied, this effect will be attached to target (if it was a targeted spell)
"trnActionUnitID":"UNIT_NAME",----------------------------------------------------- prop changer "unit" or summonable unit type or transform to unit type (NO_UNIT means empty)
"trnActionUnitIDForCaster":"UNIT_NAME",--------------------------------------------which effect to apply on caster after casting (ef. losing health) (NO_UNIT means empty)

"trnIndicatorTextureID":"SOME_TEXTURE_ID",-------------------------------------------------------------use the texture "idString" here to reference
"trnButtonTextureID":null,----------------------------------------------------------------use the texture "idString" here to reference - for unique button (if the deafult the summoned unit image is not good enough - *more details below)
"buttonTextureWithBackground":false,-----------------------------------------------if set, if set you can explicitely tell the engine if the button is with or without button background
"trnProjectileSpriteID":null,---------------------------------------------------------------use the sprite "idString" here to reference
"trnActionTextureID":null,-----------------------------------------------------------------use the texture "idString" here to reference
"trnSpotAnimationSpriteID":null,---------------------------------------------------------use the sprite "idString" here to reference
"trnDecorSpellcastSpriteID":"SOME_SPRITE_ID" ----------------------------------------you can reference a sprite in graphics.json to show when the unit casts the spell, it is shown during spellcast and fades out in (on texture defined) amount of sec after spellcast.

"chancePercent":1.0,----------------------------------------------------------------chance of casting the spell, here use 1=100% if you want to be always, // Also on WEAPON_SLOT_1,WEAPON_EFFECT_SLOT_HEAL the probability to take effect on targeted/damaged unit (eg. is weapon fire effect sticks on enemy or not)
"lastsTurnNr":0,-----------------------------------------------------------------------not used here

"effectBehaviour":"INSTANT",--------------------------------------------------------effect behaviour (see above)
"effectTargets":"HIMSELF",-----------------------------------------------------------tagert types (see above)
"trnSystemSpecialEffectID":"SYSTEM_SPECIAL_EFFECT_SUMMON ",--------------------------------------------------------Special effects (see above), here this is the summon unit
"effectTriggers":["ON_DAMAGED"], ----------------------------------------------------------------------- what event triggers the effect: ON_DAMAGED, ON_DAMAGED_AMOUNT, ON_DIED, ON_KILL_ENEMY, ON_DAMAGES, ON_DAMAGES_AMOUNT

"groups":["GROUP1", "GROUP2"], -------------------------------------------------- the group(s) of this effect (used in eg. removesEffectGroups), you can configure any string value here
"removesBuffs":"ENEMYSPELLS", --------------------------------------------------- removes buffs debuffs or all (eg. poison/slowing etc) ENEMYSPELLS/ALL/NONE Beware! removesEffectGroups relies on this!
"removesEffectGroups":["GROUP1", "GROUP2"], ----------------------------------- list of effect groups that effects will be removed when this effect applied (as instant or enchantment), combines with removesBuffs! "NONE" considered as "ALL"


"castRangeModifier":0,---------------------------------------------------------------- it can modify the spell range relative to caster default spellrange (eg +3)
"cooldownTurnNr":0,------------------------------------------------------------------If you want the spell has cooldown (caster needs to wait X turns before casting it again.)

"specCost":null,-------------------------------------------------------------------------special cost type (see above)
"specCostNr":1,--------------------------------------------------------------------------special cost amount (eg. 3 nearby corpses)
"trnSpecCostTypeList":{
"categories":["U_CHEAP_MELEE","U_BURNABLE", "U_BUILDING_SIZED_UNITS"],
"unitTypes":["UNIT_ORNITHOPTER"]
},------------------------------------------------------------- special cost type listt to be sacrificed: eg you can list only goblins, by category or specify exact types

"environmentalDef":{"density":1, "range":1}, -----------------------------------------------------------// sets the range and density to use for area effect (usable on SYSTEM_SPECIAL_EFFECT_ENVIRONMENTAL/SYSTEM_SPECIAL_EFFECT_TARGET_AND_AREA), density: dont use on stickers!*
// density: the percent drop on each tile distance from center eg. 0.3 means damage * 0.3 on distance 1, damage * 0.3 * 0.3 on distance 2

"trnRequires":["TECH_X","TECH_Y"],-----------------------------------------------------------------------required techs to be owned before use this effect
"removingWeaponSlotTypes":["HEAL", "MEND", "SPELLCAST", "WP1", "WP2"], ----------------------which type of action removes this effect (eg burning removed by MEND)


String[] trnAffectedEffectDefs;-------------------------------------------------------------------------- //the list of effect IDs that can be target of the given effects (eg. SYSTEM_SPECIAL_EFFECT_LASTS_TURN_MODIFIER effect)
ArrayList<String> affectedEffectGroups; ---------------------------------------------------------------//if set than all effect marked with these groups are affected

public Integer dataInt; //an additional data if needed (eg. SYSTEM_SPECIAL_EFFECT_LASTSTURN_MODIFIER will havve its parameter in it)
public String dataString; //an additional data if needed (eg. SYSTEM_SPECIAL_EFFECT_TRANSFORM_BY_GROUP will have its parameter in it)


"priority":0-------------------------------------------------------------------------------The priority the AI should use when selecting weapons against targets: 0 for irrelevant ones, about 900 on strongest effects, 100-800 the average effects

}
* dont use on stickers!*: means dont use this setting on an ability that casts effect to units that "sticks" and should be removed by disenchant, or vanishes in time and so on. (reason: on effect removal unit will not return to its original values) - so buggy

Deprecated ones:
"isOneTimeSpell":false,---------------------------------------------------------------If canster can cast it on only once in his lifetime
//depracated: was not ever implemented, and you can use big cooldown instead (but not insane big please)




Button image appearance

Here see how button image is drawn:
1st prior if u explicitely gave Button image in trnButtonTextureID - than this will appear there
(image includes the button background too in AOf+AOS, in AOW it means only the decoration. You can override with "buttonTextureWithBackground")
2nd prior using the trnActionTextureID over the button background (like a cannonball shot cannonball image in AOF/AOS)
3rd prior in summon type of effect then the summoned unit's image is used over the button background (like the green dragon in AOF)
4th prior if it is a transform effect than a "transformation" image is shown over the button background
5th prior if a "requires" unit/tech is set then the image of that unit/techs is shown over the button background

Extra simplification on images

button case:
if trnButtonTextureID image set uses that
if not, than if trnActionTextureID set uses that
if not, than if trnProjectileSpriteID set uses that

action case (what appears on targeted unit(s):
if trnActionTextureID set uses that
if not, than if trnProjectileSpriteID set uses that
if not, than a built in default image

action animation case (what animates from caster - to unit):
if trnActionTextureID set uses that
if not, than if trnProjectileSpriteID set uses that
if not, than a built in default image

so in simple cases you need to set only the trnProjectileSpriteID and you are done.

Triggered effects
About triggered effects you can make triggers "when" the effect should be executed (eg. if unit kills another unit)
A little complex the implementation (read: shit) but here is a help on it
2 ways you can define such effects
1. SIMPLE case: you define a TRIGGERED_EFFECT in an effect json (on unit kills an enemy, like Veteraning), and inside that single json you set a trnActionUnitID value (that will change the unit properties, eg. on veteraning some extra power)
2. COMPLEX case:
- you define a TRIGGERED_EFFECT json where you define NO trnActionUnitID! but you define a trnEffectDefIDRelated to a new effect
- you define the second trigger that is doing the job
- this case you can also set chancePercent to have probability on success
(remark: i suggest naming the TRIGGERED_EFFECT type json files to start with "trigger_" )
User avatar
Sunrise Samurai
Posts: 2678
Joined: Thu Jun 18, 2015 11:21 pm
Location: Florida, U.S.

Re: Effect definition json

Post by Sunrise Samurai »

Can you compile a zip of a bunch of AoF abilities? Please include at least raise dead, fireball, convert, one aura, and one enchantment​ for us to study.
The glorious sun rises again
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Effect definition json

Post by Stratego (dev) »

Not all AOF and AOS units/effects and other things are defined in jsons *, but here what are in AOF currently (effects, units, and so on - everything in AOF)
AOFJsons.zip
(306.56 KiB) Downloaded 208 times

* : AOW will be the first that is only JSON definition based.
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

"specs":["IS_NEGATIVE_EFFECT"] -- set this to make the effect a negative one like slowing (if not set than considered positive like strengthening), now in AOF disenchant uses if it wants to remove effect or not
new spec.

means all negative effects should be marked (not only sticky ones)
Midonik
Posts: 5325
Joined: Mon Sep 05, 2016 5:27 pm
Location: Poland

Re: Game definition jsons - Effect definition json

Post by Midonik »

Can I make disenchant work only on few types of effects, not all? Probably not...
Support new AoS variant, Age of Galaxy: http://ageofstrategy.net/viewforum.php? ... 608408ebc8
All help will be welcome.
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

The current disenchant removes all.
We need dedicated ones if u need that
Midonik
Posts: 5325
Joined: Mon Sep 05, 2016 5:27 pm
Location: Poland

Re: Game definition jsons - Effect definition json

Post by Midonik »

Currently all is ok too.
Support new AoS variant, Age of Galaxy: http://ageofstrategy.net/viewforum.php? ... 608408ebc8
All help will be welcome.
User avatar
makazuwr32
Posts: 7830
Joined: Tue Oct 17, 2017 9:29 am
Location: Moscow, Russia

Re: Game definition jsons - Effect definition json

Post by makazuwr32 »

but can we add undisenchantable effects?
makazuwr32 wrote: Mon Sep 16, 2019 7:54 amWhen you ask to change something argument why...
Put some numbers, compare to what other races have and so on...
© by Makazuwr32™.
AoF Dev Co-Leader
Image
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

Yes. Which would those be?
User avatar
makazuwr32
Posts: 7830
Joined: Tue Oct 17, 2017 9:29 am
Location: Moscow, Russia

Re: Game definition jsons - Effect definition json

Post by makazuwr32 »

Many Runic spells that target units i suggested for dwarves.
Rune battle priest all his spells must be undisenchantable.
Rune mage 1 spell is undisenchantable.

Also another question - can we add damage to summoned/elemental unit types for disenchant spell?
makazuwr32 wrote: Mon Sep 16, 2019 7:54 amWhen you ask to change something argument why...
Put some numbers, compare to what other races have and so on...
© by Makazuwr32™.
AoF Dev Co-Leader
Image
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

runes: then what is the counterspell for them?

summoneds: could be, but needs coding , put into the needs list posts to be "vodted"
User avatar
makazuwr32
Posts: 7830
Joined: Tue Oct 17, 2017 9:29 am
Location: Moscow, Russia

Re: Game definition jsons - Effect definition json

Post by makazuwr32 »

Runes don't need counter spell but runic magic's weaknesses are
1. long cooldown (4/6/8 turns cooldown) 2. short time effect (1-2 turns exept 2 of them)/until used (these 2 will have long time cooldown and both are castable by unique unit only - the one that can be trained only one per player)

I designed single target runic spells that they will be powerful but have long time cooldown and short time effect

Also another question - can we add some sort of spell that forcibly sets cooldown of target unit's abilities (all) to target value?
makazuwr32 wrote: Mon Sep 16, 2019 7:54 amWhen you ask to change something argument why...
Put some numbers, compare to what other races have and so on...
© by Makazuwr32™.
AoF Dev Co-Leader
Image
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

runes: ok it is easy to make a setting to be exceptional spells that are not removable by disenchant - email me about it please

setting cooldown to abilities: harder, lets put it too "needs" vote
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

"trnSpecCostTypeList":{
"categories":["U_CHEAP_MELEE","U_BURNABLE", "U_BUILDING_SIZED_UNITS"],
"unitTypes":["UNIT_ORNITHOPTER"]
},------------------------------------------------------------- special cost type listt to be sacrificed: eg you can list only goblins, by category or give exact types
User avatar
makazuwr32
Posts: 7830
Joined: Tue Oct 17, 2017 9:29 am
Location: Moscow, Russia

Re: Game definition jsons - Effect definition json

Post by makazuwr32 »

Oh. This will come in handy for mounting ability of eagles.
makazuwr32 wrote: Mon Sep 16, 2019 7:54 amWhen you ask to change something argument why...
Put some numbers, compare to what other races have and so on...
© by Makazuwr32™.
AoF Dev Co-Leader
Image
User avatar
General Brave
Posts: 4662
Joined: Thu Oct 19, 2017 3:12 am
Location: The Four Point Military Academy.

Re: Game definition jsons - Effect definition json

Post by General Brave »

Will be useful.
Wise, Might, Loyalty. Forever stands Warfell.
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

new spec option:
IS_COOLDOWN_ON_SPAWN -- if set AND it has cooldown, than the cooldown will start right on unit spawning
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

new option to set transformation from now not on unt but on effect:
"trnTransformTo" ----------------------------------------------------------------------transformation ID, used for case of SYSTEM_SPECIAL_EFFECT_TRANSFORM1, if null than the Unit.transformTo1 value will be used
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

new trnSpecs options

AMOUNT_BY_STRENGTH, // if set than the caster unit's strength will mutiply the "effect" (effect will run this many times)
AMOUNT_BY_HP, // if set than the caster unit's hp will mutiply the "effect" (effect will run this many times)

new button texture setting:
"buttonTextureWithBackground":false,-----------------------------------------------if set you can explicitely tell the engine if the button is with or without button background
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

new setting:
"removingWeaponSlotTypes":["HEAL", "MEND", "SPELLCAST", "WP1", "WP2"], ----------------------which type of action removes this effect (eg burning removed by MEND)
User avatar
godOfKings
Posts: 3302
Joined: Fri Sep 22, 2017 4:50 pm

Re: Game definition jsons - Effect definition json

Post by godOfKings »

Where should it b written, on the spell effect json?
There is no place for false kings here, only those who proves themselves to b the true kings of legend, or serves under me

For I watch over this world looking for those worthy to become kings, and on the way get rid of the fakes and rule over the fools
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

yes under effects folder (this topic is about jsons in effects folder)
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

an old setting was not documented here, so here new:
"removesBuffs":"ENEMYSPELLS", //removes buffs debuffs or all (eg. poison/slowing etc) ENEMYSPELLS/ALL/NONE
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

new special cost option:
ACTION_POINT //if set than it requires extra action points or even 0 action point, altering the default 1 action cost
User avatar
Dagravian
Posts: 938
Joined: Tue Sep 06, 2016 6:20 am
Location: Terra - Brasil

Re: Game definition jsons - Effect definition json

Post by Dagravian »

Can you add something to measure self-developed behaviors of effects?
Stay Awesome!
(ノಠ益ಠ)ノ彡┻━┻
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

sorry, what do u mean? :)
User avatar
Dagravian
Posts: 938
Joined: Tue Sep 06, 2016 6:20 am
Location: Terra - Brasil

Re: Game definition jsons - Effect definition json

Post by Dagravian »

I want something that measures exactly that... The behavior of effects on units over the time.
Stay Awesome!
(ノಠ益ಠ)ノ彡┻━┻
User avatar
Dagravian
Posts: 938
Joined: Tue Sep 06, 2016 6:20 am
Location: Terra - Brasil

Re: Game definition jsons - Effect definition json

Post by Dagravian »

Should i create a post to explain in details what i mean?
Stay Awesome!
(ノಠ益ಠ)ノ彡┻━┻
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

sorry can u write an example, from this i dont have tiny little idea what u thinking :)
(maybe my bad english sorry)
Stratego (dev)
Site Admin
Posts: 15734
Joined: Fri Apr 25, 2014 9:28 pm

Re: Game definition jsons - Effect definition json

Post by Stratego (dev) »

DoomsdayDragonfire wrote: Wed Aug 28, 2019 5:20 am Should i create a post to explain in details what i mean?
would be awesome!
Post Reply

Return to “Game Definition .JSON”