You must be logged in to post messages.
Please login or register

Scenario Design and Discussion
Moderated by HockeySam18

Hop to:    
Welcome! You are not logged in. Please Login or Register.186 replies, Sticky
Age of Kings Heaven » Forums » Scenario Design and Discussion » UP 1.5 Effects & How to use them in Maps
Bottom
Topic Subject:UP 1.5 Effects & How to use them in Maps
« Previous Page  1 ··· 4 5 6  Next Page »
BF_Tanks
Squire
posted 08-31-17 09:19 AM CT (US)         
Hello friends! This post was last updated 23/08/2019!

This thread is for discussing User Patch 1.5 and its application as a designer's tool. This first post will give you an overview of the most powerful element; UP-Effect, but following this are more posts going into more detail or other topics.

Post 2 - UP-Effect vs UP_Attribute
Post 3 - Attributes and Effects
Post 4 - Other features

Investigations are posts documenting research into particular elements of UP-Effects and their uses:
#1 - Using UPGRADE_UNIT: Achieving Off-Grid Resource Piles In-Game.
#2 - Using UPGRADE_UNIT: Preventing Villagers taking jobs.
#3 - Train Location: Does Class Matter?
#4 - Train Location: Type differences and cool ideas.
#5 - Using UPGRADE_UNIT: Examining Cross-Type Upgrading & Upgrade Leftovers.
#6 - Using UPGRADE_UNIT: Cross-Type Limits and Freeze-Frame Units.

Extra Info:
Full List of all non-UP Resources, from AGE 2019.

What is the "UP Effect"?
The UP Effect, or up-effect, is a special feature of UserPatch 1.5-onwards that -- put simply -- allows some basic data modding within the Scenario Editor through manipulation of tech effects.
Tech effects can alter a lot more attributes than the standard editor, accross every unit of that ID (or class).

UserPatch has opened the doors to entirely different games distributed through scenarios and random map scripts. It is, in a word, Brilliant.

I'm over-exaggerating how great it is.
  • Well, kinda. Let's look at it from a technical view.

    "up-effect" works by using AoC's Technology Effect system. Everything that can be achieved through technology effects can be achieved through up-effects (with some notable additions)

    Scripter64, creator of UserPatch, has provided some outlining documentation on how to use the up-effect, how it can translate to random map scripts, and provided a few examples. However, I feel this doesn't go into much depth and doesn't serve well enough to get your creative juices going.
    I have also been answering a lot of questions on the topic of using up-effects, and what they can achieve.

    First:
  • There are two types of up-effect.
    These are up-effect, and up-attribute. I will talk more about up-attribute later.

    Second:
  • up-effect can be a little confusing to use at first.
    But you'll get the hang of it!

    How do I use one?
    To use a up-effect, you need a Display Instructions trigger. To prepare it for an up-effect, set the timer to 99999999 (UPDATE: The latest beta now only needs 99999 or more!) and the number field to 9 -- like so:

    One thing you might struggle with is remembering all the 9's for the timer field. You can't just put any old number in there (unless Scripter changes that in the future), you need to put 8 9's. When typing it, I tend to 4 9's, then pause a split second, then the other 4 9's, to keep track.

    Next, we start the "Message" field with "up-effect". Until you get used to it, I suggest also completing it with 0,0,0,0,0,1 -- Like this:

    This should hopefully help you to keep track of all your numbering. The up-effects all rely on numbers, and there must always be six of them. Let's dissect them:

    In Scripter's documentation, he writes:
    up-effect player,effect,item,attr,value,style
    - player: 0 for default (all) or 1-8 for a specific player
    - effect: the id of an Effect such as SET_ATTRIBUTE (0)
    - item: the id of the Item to modify such as VILLAGER_CLASS (904)
    - attr: the id of the Attribute such as ATTR_HITPOINTS (0)
    - value: the value to set
    - style: 2 if value should be divided by 100; otherwise 1
    Looking at that, a quick glance might make you think that you can write something like "up-effect 0,SET_ATTRIBUTE,VILLAGER_CLASS,ATTR_HITPOINTS,200,1" but this isn't correct. The reason Scripter has written these block-capital words is probably due to the way up-effects can be put into random map scripts, using these words instead of numbers like we do in a scenario.

    So, Scripter provides an example:
    up-effect 0,0,904,0,100,1
    effect_amount SET_ATTRIBUTE VILLAGER_CLASS ATTR_HITPOINTS 100
    The top line is what you'd do in our Display Instructions trigger. The bottom line is what you'd put in your random map script. I haven't experimented with the random map script functions yet, and probably won't ever. So I won't talk much about them here, but it is useful to note that there's potential for making random map scripts that, for example, incorporate X-Patch's balance changes, without needing the mod. This is something that, whilst I won't use it (probably), should definitely not be overlooked as a cool side-effect.

    So instead of just copying Scripter's example, let's do our own.

    A quick unit modification example
    First, we want to choose the player for our effect. You can use 0, 1, 2, 3, 4, 5, 6, 7 or 8. 0 means "All Players", 1-8 should be self explanatory. I haven't experimented with the Gaia attributes much, but as I understand it -- if you want to specifically effect ONLY gaia, you need to set player number to 0 and use negative numbers in your "effect" field.
    I'm going to use player 1.

    Next, we want to decide on our "effect". I'm going to keep things simple, and ignore everything that doesn't affect a unit. In the documentation, under file "UserPatchConst.rms", Scripter writes:
    #const SET_ATTRIBUTE 0
    #const ADD_ATTRIBUTE 4
    #const MUL_ATTRIBUTE 5
    #const ENABLE_OBJECT 2
    #const UPGRADE_UNIT 3
    If you were writing a Random Map Script, you'd use these const names. We however are only interested in the numbers.

    So, these numbers:
  • 0 will set an attribute outright. For example, Health, Range, Movement Speed, etc. will be set to the value you specify.
  • 2 will enable or disable a unit. This means that you can, for example, enable a Britons player to train Plumed Archers instead of longbowmen by doing up-effect 0,2,8,0,0,1 followed by up-effect 0,2,763,1,0,1.
  • 3 will upgrade a unit. This is what happens when you, for example, research Man-At-Arms. There's various things you can do with this and all of them are cool. Shape shifting units? Changing looks but keeping stats? It's all there.
  • 4 is like 0, but ADDs to what already exists. For example, you can ADD 50 HP to a 100 HP unit, and get 150 HP. I don't want to insult your intelligence by providing an example image though.
  • 5 MULTIPLIES the attribute, and here you might want to be careful. You could, if you set the "Style" wrong, accidentally multiply a unit's speed by 110x, instead of 1.10x. It's also worth noting that stacking Multiplied attributes is exponential. It multiplies the previous stats, NOT the BASE stats. If you multiply 100 HP by 1.10, then do it a second time, the second time around it will be multiplying 110 HP by 1.10.
    35+10% HP-> 39+10% HP->


    So, have you decided what you want to try? I'm going to SET, so my second number in the up-effect line will be 0. It looks the same as before, but yours might not.


    The third number is a big deal. This is what we're going to effect. There's two ways we can do this.
  • Use the Unit ID number.
  • Use the Class ID number, + 900.
    up-effects can effect any individual unit whose ID is between 0-900, and 1000-1959. IDs in the 900-999 range are actually reserved for counting data (According to Scripter), so he's made use of them for Classes. This means that if you want to affect a Longbowman like in my above example, you want "8". But if you want to affect ALL archer units, you'd use "900", because an Archer is class 0.
    For reference, Here is a post I made, showing the various classes (and Attributes) listed in AGE 2017.

    In our experiment, I'm going to pick number 24 - The Crossbowman. Now my up-effect line looks like this:

    (I'll award bonus points to anyone who can point out how dangerous this line is for my crossbowman, right now.)


    Our fourth number is also an important one, and it changes depending on our second number. If our second number is 0 (Set), 4 (Add) or 5 (Mult.), this fourth number is an Attribute ID. But, if our second number was, for example, 2 (Enable Object), then this fourth number would be either 0 (To Disable), or 1 (To Enable). Scripter's documentation explains some of these, albeit a bit confusingly. EG, for "Enable Object" he writes:
    /* Type: ATTR_DISABLE or ATTR_ENABLE, Value: 0 */
    You have to scroll further into the document to even find where "ATTR_DISABLE" and "ATTR_ENABLE" translate from Random Map Script text to a Scenario number:
    /*--------------------------------------*/
    /* Define Effect Type Constants */
    /*--------------------------------------*/
    #const ATTR_DISABLE 0
    #const ATTR_ENABLE 1
    So, in our case we just want to do some simple messing with Attributes. So, your second number should be 0, 4 or 5. We want to then pick an Attribute from the list:

    But wait!
    Scripter has also added some special ones:
    /* New: Category 80+ */
    #const ATTR_GARRISON_TYPE 30
    #const ATTR_DATA_FLAGS 31

    /* New: Category 70+ */
    #const ATTR_HERO_STATUS 40/* ADD_ATTRIBUTE append flags */
    #const ATTR_ATTACK_DELAY 41/* ADD_ATTRIBUTE enabled */
    #const ATTR_TRAIN_LOCATION 42
    #const ATTR_TRAIN_BUTTON 43
    #const ATTR_BLAST_LEVEL 44
    #const ATTR_HERO_HEAL_TIME 45/* ADD_ATTRIBUTE enabled */
    #const ATTR_SHOWN_ATTACK 46/* ADD_ATTRIBUTE enabled */
    #const ATTR_SHOWN_RANGE 47/* ADD_ATTRIBUTE enabled */
    #const ATTR_SHOWN_MELEE_ARMOR 48/* ADD_ATTRIBUTE enabled */
    #const ATTR_SHOWN_PIERCE_ARMOR 49/* ADD_ATTRIBUTE enabled */

    /* New: Category 10+ */
    #const ATTR_NAME_ID 50
    #const ATTR_CREATE_SDESC_ID 51
    #const ATTR_CREATE_LDESC_ID 52/* unused (becomes ATTR_CREATE_SDESC_ID + 20000) */
    #const ATTR_TERRAIN_ID 53
    #const ATTR_TRAITS 54/* ADD_ATTRIBUTE append flags */
    #const ATTR_CIV_ID 55
    #const ATTR_PIECE 56
    #const ATTR_DEAD_ID 57
    There's a lot you can do. I've made a post following this one listing all of the attributes, how they're used and what they can do. For this example, I'm just going to pick attribute ID 16 -- But I highly recommend experimenting.

    If you look at the list of attributes, you'll be able to find Attribute 16 and get an idea of what it can do. I'll give you a clue -- It's used by the tech "Chemistry". I advise you skip Attribute's 9 and 8, as they need some special maths which I will explain later.

    Our fifth number is the "Value". In my case, I need a Unit ID. In some cases you might want to use percentages, or float values. For that, you'll need to remember that a value of "100", with a "Style" (The sixth number) of 2, will make it "1.0". You may be wondering why you can't just write in "1.0", and I wonder that too. But clearly -- if that was possible then Scripter would of let us do it that way.

    So, I've went ahead and picked a Unit ID for my Attribute 16:


    My "Style" -- The sixth number -- will remain as 1. This is because I don't need to convert my fifth number into a percentage. If you were doing something like, adding 10% to the Longbowman as above, your Style here would be 2 and your Value would be 110. This turns into 1.10x, or 110% of the original value. The Effect (Second number) would be 5, because you're Multiplying.

    Something to bare in mind is that this projectile change could be overwritten if I were to later research Chemistry.

    Now, this example might be a bit extreme. Changing projectiles is a very specific effect. But, hopefully you've experimented and chosen your own values and attributes to change. Be careful when changing Projectile IDs, though. If you choose an ID that is not a valid projectile unit, the likely case will be that your attacks will fire no projectile and do no damage, and unlike Melee Units that have their projectile ID set to -1, a projectile ID set to something like a Watch Tower would cause the game to try spawning a watch tower and failing, thus the game would deduce that the projectile did not hit and do no damage.

    This could be drastic in a scenario where the projectile might not change for a long time into the map, on a specific unit. The map designer might not even notice that he's firing blanks, because he's not firing a proper Projectile unit.

    Off the top of my head, here's some other examples of up-effects for units:
    up-effect 1,0,550,0,32767,1 -- The maximum health a unit can have without using negative damage object triggers.
    up-effect 2,5,555,5,555,2 -- Gives all of player 2's Elite Huskarls trained at the castle 555% their regular speed.
    up-effect 1,0,504,57,4,1 -- Sets the dead unit ID of player 1's Watch Tower arrows to spawn an archer.
    up-effect 1,0,173,42,903,1 & up-effect 1,0,173,43,14,1 & up-effect 1,2,173,1,0,1 -- Enables the production of King arthur at player 1's castles.
    Something to remember;
    When doing up-effects, each up-effect should be on a separate line, like this:

    And a Display Instructions effect can only hold so much text. There will probably come a time where you need to use multiple effects.

    Okay, that's nice and all. What about the other effects we ignored?
    First, let's look at MOD_RESOURCE (Effect ID 1) and MUL_RESOURCE (Effect ID 6). Contrary to my original belief, these aren't for modifying resource costs. These are actually working just like Tributes.

    Here's an example:
    up-effect 1,1,4,1,100,1
    The Player is 1, the Effect is 1 (MOD_RESOURCE), the Item is 4 (Population Headroom), the Attribute is 1 (When using MOD_RESOURCE, use 0 or 1. 0 SETS, 1 ADDS.), the Value is 100, and the Style is 1.
    What this does is simple -- adds 100 Population Headroom to Player 1. It doesn't go over the player's Pop Cap max, though.

    So what's the point of this, if I can use Tributes for the same effect? (And oh boy, can you use Tributes. UserPatch allows you to select every available resource for Tributes, including ones added by Scripter.)

    Well, unlike tributes you can now:
  • Multiply resources
  • Use float values. EG: Faith Recharge Rate (Resource 35) is by default set to 1.6 -- You can't do that with Tributes.

    Furthermore, these tributes allow you to have control over the Weather and Fog lighting systems in UserPatch 1.5. A very good article on the University Here has more details on it.

    Secondly, let's look at Tech modifications. This one is a bit weird, because there's two ways of going about changing the costs.

    Before we get onto that, though; let's look at Effect 7 (Enable Tech). This work just in the way that disabling/enabling techs through the Research Technology triggers work, with the exception that you can enable/disable techs that aren't listed in the vanilla editor. However, you can't Research techs with this, only Enable or Disable them. This and Effect 102 (Disable Tech) are aimed more for use in Random Map Scripts, where triggers don't apply.

    So what should we care about?
    I've been having difficulty working with the Tech effects. For example, I can't seem to get Effect 8 to work correctly. Hopefully Scripter can enlighten us.

    What I have been able to get working, is Effect (The second number) 100, 101 and 103.
  • Effect 100 SETS a tech cost
  • Effect 101 ADDS to a tech cost
  • Effect 103 MODS a tech time, using Attribute (the fourth number) 0 for Set or 1 for Add.

    So, for example, you might want to take Loom for Player 1 and make it cost 500 Gold. You'd do that with this line: up-effect 1,100,22,3,500,1

    However in my experience I've been unlucky with adding new resources to the costs. You can also use Effect 8 (MODIFY_TECH) to achieve the same effects, but again, I can only seem to affect costs that already exist. I can Change the gold cost of Loom, but I can't make it have a Stone cost.

    One thing to bare in mind; If you alter a resource's cost, you have to Disable then Enable the tech for the costs to actually update. So with my Loom example, I have three triggers. One sets the cost, one Disables (Research Technology, with number field set to 2) and then Enables it again (Research Technology, with number field set to 1).

    What about GAIA effects?
    Using the GAIA effects is a little unknown to me. I assume they're specifically for affecting units owned by GAIA, so lets try it out: I'll use the line "up-effect 0,-1,4,0,200,1" -- In theory this should set GAIA archers to have 200 HP.

    Seems to be a success:
    vs


    So I can assume from these results that you need the Player (the first number) to be 0, to affect all players. Then the Attribute set to one of the negatives that only affect GAIA.
    From Scripter's Documentation:
    #const GAIA_SET_ATTRIBUTE -1
    #const GAIA_ADD_ATTRIBUTE -5
    #const GAIA_MUL_ATTRIBUTE -6
    #const GAIA_MOD_RESOURCE -2
    #const GAIA_MUL_RESOURCE -7
    #const GAIA_SET_TECH_COST -101
    #const GAIA_ADD_TECH_COST -102
    #const GAIA_MOD_TECH_TIME -104
    #const GAIA_ENABLE_OBJECT -3
    #const GAIA_UPGRADE_UNIT -4
    #const GAIA_DISABLE_TECH -103
    #const GAIA_ENABLE_TECH -8
    #const GAIA_MODIFY_TECH -9
    #const GAIA_SET_PLAYER_DATA -10
    Performance
    I've not noticed any performance penalties that don't normally occur. Due to the way up-effects work, the game handles it really well, just like any Tech effect. up-effect can also be used to affect over 300 units at once, and also affects units not even created yet. For example, in a multiplayer RPG I've been working on as a "showcase" of UP effects, I have a scaling difficulty where every 25 losses, the enemy player gains 10% HP on all their units, created or not. Looping up-effects also has a very little impact. Almost unnoticeable unless you have a lot of them going off at once.

    The same performance nicety's can't be extended as much to up-attribute, though, and we'll talk about that in the next post...

    Proud Member of Black Forest Studios
    Co-creator of Silent Evil - Voted Best Multiplayer Scenario of 2009
    and The Seas of Egressa - Voted Best Multiplayer Scenario of 2010

    [This message has been edited by BF_Tanks (edited 08-24-2019 @ 05:32 PM).]

  • AuthorReplies:
    BF_Tanks
    Squire
    posted 08-23-19 04:18 PM CT (US)     176 / 186       
    @Kata:
    I'm pretty sure it's the same for WK.

    ---

    More investigation into TRAIN_LOCATION;

    I've set up three UP-Effects that should allow me to build a Pavilion from a Villager:

    Firstly, I set the Pavilion's TRAIN_LOCATION to ID 118 (Male Builder)
    up-effect 1,0,625,42,118,1
    Why 118 and not 904 (Villager Class) or something more encompassing?
    When I tried with 904, or 83 (Male Villager), the button would never appear, even when trying with a standard building that should be available. I think building buttons are hard-coded to come from Unit ID 118, but it bares some experimentation to be sure.


    Secondly, I set the Pavilion's TRAIN_BUTTON to 13, which should be a safe, empty spot in his build menu.
    up-effect 1,0,625,43,13,1
    In-game:




    A quick note on Interface Kind and build icon pages:
    Every unit in the game has an "Interface Kind" value which determines what buttons are available on the UI. Most buildings have an Interface Kind of 2, which is for all Buildings on Build Page 1. (Economic Buildings)


    Castles, like all Military buildings, have Interface Kind 10, which is almost identical to Interface Kind 2, except the button will appear on Build Page 2. (Military Buildings)



    Here's some ideas using this on other buildings;

    A Tower-defence with individual tower types, buildable from the menu.


    A game where players can only train units from Monuments, built from the menu.








    Let's get a bit more experimental;-

    "Buildings" are a Type-80 Unit, but I want to see what else is able to be created from our villager. A Monument is the most interesting thing tried so far, because it's a Class 1 (Artifact) unit, not a typical Class 3 (Building) or other building-like Class.

    From tests, it seems that Type-70 (Combatant) units can only build Type-80 (Building) units, and only if those Type-80's have an Interface Kind of 2 or 10.
    Furthermore, Build pages are tied to Unit ID 118 (Male Builder). Buildings must have 118 as their Train Location to show up on the build pages.

    However, Type-80 units aren't restricted to just Type-70. I was able to queue up an Archery Range (Interestingly it wouldn't queue up if I was housed, despite being a building that doesn't cost pop.)


    Although, these results weren't quite expected:

    I guess I have to build it twice now.


    There's some cool potential here with the idea behind Monuments as key buildings that can produce other buildings around them, acting as capturable, upgradeable fortresses.

    You can even create OLD-EXPLORER's, which is kinda neat:

    Proud Member of Black Forest Studios
    Co-creator of Silent Evil - Voted Best Multiplayer Scenario of 2009
    and The Seas of Egressa - Voted Best Multiplayer Scenario of 2010

    [This message has been edited by BF_Tanks (edited 08-23-2019 @ 04:20 PM).]

    BF_Tanks
    Squire
    posted 08-24-19 08:30 AM CT (US)     177 / 186       
    Kataphractoi used UPGRADE_UNIT to place Bridges on land without changing the underlying terrain that happens when a bridge is first built:


    He did this through a set of up-effects to upgrade various buildings into bridge pieces:
    up-effect 3,3,716,607,0,1
    up-effect 3,3,713,606,0,1
    up-effect 3,3,715,739,0,1
    up-effect 3,3,717,740,0,1
    up-effect 3,3,714,738,0,1
    up-effect 3,3,1198,741,0,1
    up-effect 3,3,155,610,0,1
    up-effect 3,3,72,609,0,1
    up-effect 3,3,598,608,0,1
    up-effect 3,3,1199,743,0,1
    up-effect 3,3,1200,742,0,1
    up-effect 3,3,117,605,0,1
    up-effect 2,3,713,605,0,1
    ---

    Seeing this, I looked more into UPGRADE_UNIT, wanting to see what the limits are.

    In testing, the first thing I wanted to be sure of was upgrading to Type-80 (Building). For example, upgrading a Militia to a House or a Flag to a Bridge, but nothing I tried worked. This also affected Trebuchets, as they are also Type-80 -- I couldn't upgrade an Onager to a Trebuchet, for example.
  • No matter what, Upgrading to a Type-80 will crash.

    However, Upgrading from a Type-80 doesn't always, and may have interesting uses. I was able to upgrade a Watch Tower to a Villager, and I got a square selection box (until I told it to do anything)

    There were also some odd LOS artifacts left behind:


    Furthermore, I found that Type-70 and Type-80 can upgrade to Type-60 (Projectiles)


    Interestingly, the projectiles inherit the LOS of the unit they upgraded from, which could be useful for large range Map Revealers that can easily be hidden amongst eye-candy, using the Hand Canoneer projectile.


    Another thing noticed here was that the projectile had physical size and I couldn't move onto the same tile.

    I have reason to believe this inheritance of various attributes lasts until the upgraded unit actually does something, as seen with the villager earlier.

    So far, my tests have all been of units that are "Existent" or "Enabled" for that Civilisation. If I try upgrading to, for example, a Relic (being a Type-70 only enabled for GAIA), A non-gaia civ unit won't upgrade -- But this gave me another idea.

    I want to see to what extent units inherit things from a previous unit through UPGRADE_UNIT.

    Taking a GAIA Crossbowman, I upgraded it to a Piece of the True Cross, which worked (and why not, they're both Type-70) -- The more exciting part was walking over to the Piece with a Player owned unit, and finding the Piece had inherited the auto-convert of the GAIA crossbowman.



    Being yours, you can't even pick it up with a Monk.


    There's some very neat ideas coming to mind - knowing the auto-convert flag remains. Player-controlled wildlife, for example, being one of them.


    Using a Hawk as a map revealer. Note; It can't be selected so control must come through triggers.


    One-time converting sheep (which seems to be able to auto-attack?)

    Proud Member of Black Forest Studios
    Co-creator of Silent Evil - Voted Best Multiplayer Scenario of 2009
    and The Seas of Egressa - Voted Best Multiplayer Scenario of 2010

    [This message has been edited by BF_Tanks (edited 08-24-2019 @ 01:01 PM).]

  • Kataphraktoi
    Squire
    posted 08-24-19 09:43 AM CT (US)     178 / 186       
    Awesome stuff;queuing up buildings, the controllable deer, and placing buildings in the villager building GUI; all very interesting.

    I was trying to get villagers to build onagers, by the way. I did manage to get onager foundations in, and if you delete them a dead onager appears, but it doesnt work if you let it finish building. I trued using the upgrade functionality for this, turning a pavilion into an onager, but this "From tests, it seems that Type-70 (Combatant) units can only build Type-80 (Building) units," seems to suggest its impossible to make happen



    So I figured out how resource 7(relics captured) and resource 196(huns wonder bonus) work. They are not complicated but I will share my notes regardless incase someone wants to copy them.

    In order to toggle a relic victory timer, one can simply use this;
    up-effect 1,1,7,0,2,1
    In order to signify that player1 has two relics in their monastary. You can change the '2' to whatever number of relics physically exist on the map when you start the scenario. In this case two relics in the corner will do the job.
    In order to toggle this off, you just do like so:
    up-effect 1,1,7,0,0,1
    Meaning player1 no longer has any relics garrisoned.

    In order to adjust the years needed to win a relic or wonder victory, you can use the following:
    up-effect 1,1,196,0,20000,1
    This adds an entire 2000 years to whatever the timer has on it to start with. For example on a tiny map it would now take 2200 years to win via relic\wonder after firing this off. The player doesnt matter since this technology effects all ingame players. That large value of 20,000 controls the time...as you can see its 10x as large as the ingame year counter will say. Note that the Atheism tech no longer does anything with this in play.

    And about resource 55 All Relics Captured...well, I have no clue. No value I put in did anything.

    "Excellent could be any map that has the quality of a ES random map or ES scenario. AoK is an excellent, award winning game. That's where I'd start." -AnastasiaKafka

    "Hard work is evil. Bitmaps are stupid. Working on a scenario for more than one afternoon is stupid. Triggers are stupid. Testing your own scenario is stupid. The world is stupid. You are the Greatest." -Ingo Van Thiel
    BF_Tanks
    Squire
    posted 08-24-19 01:03 PM CT (US)     179 / 186       
    Lots of those resources are only used for the scoring at the end, but have a lot of uses from that. Individual kill trackers for each player is really neat.

    "All Relics Captured" might well just be a flag for the scoreboards.

    Some more info into cross-type UPGRADE_UNIT;
    Type 80 > Type-10/20/30 = Crash
    Type-80 > Type-70/60 = Safe, Unit keeps Size, LOS
    Type-70 > Type-10/20/30/80 = Crash
    Type-70 > Type-60 = Safe, Unit keeps LOS
    Type-60 > Type 10/20/30 = Crash
    Type-60 > Type-70 = Safe**
    Type-60 > Type-80 = Safe*
    Type-10/20/30 > Type-60 = Safe
    Type-10/20/30 > Type-70 = Safe*
    Type-20/30 > Type-80 = Crash
    Type-20/30 > Type-10/30 = Safe***

    *but crashes when Unit selected.
    **but units will be frozen in one frame, unselectable and have no collision. This could be useful as a statue effect, but bare in mind you need something solid beneath it to prevent walking over the graphic.

    ***but units disappear immediately after upgrade.

    Interestingly, you can use this trick to "freeze-frame" a unit, whilst not breaking its functionality as a unit. Essentially, manipulating the inheritance quirk.

    Take a normal Type-70...


    Upgrade it to an Arrow...


    Choose a different Type-70 to freeze-frame, and there you go. The unit is completely normal, but it's stuck in one frame until it gets moved. This could have uses as statues that come alive.



    Another neat thing, if you upgrade a Relic to a different unit, that unit can be picked up just like a Relic, but also be attacked and killed like a regular unit. Unfortunately I couldn't control it, though.


    Here's a gif of a spearman attacking a player-owned relic, and getting points of damage back

    Also, If you upgrade a Relic Cart to a regular unit, the unit will function normally but also be auto-converted as a Cart would, on top of being untargetable? Interesting uses here.

    When you upgrade from a Type-10 unit to a Type-60, be aware of what leftover data will go with it. In my testing, I found Resources to take over a lot to what they upgrade into -- I had a Villager able to mine gold from a projectile.

    Another interesting little thing, if you upgrade a Farm to a Mill, the villager can still work there and the mill will hold food, but it'll never be depleted. With other buildings, a small amount is depleted and then the farmer just continues gathering nothing.

    Proud Member of Black Forest Studios
    Co-creator of Silent Evil - Voted Best Multiplayer Scenario of 2009
    and The Seas of Egressa - Voted Best Multiplayer Scenario of 2010

    [This message has been edited by BF_Tanks (edited 08-25-2019 @ 04:05 PM).]

    Cataphract887
    Squire
    posted 09-02-19 03:59 PM CT (US)     180 / 186       
    Revisiting unit radius, this time I did succeed in getting it to work, for example;
    up-effect 1,0,38,3,5,1
    up-effect 1,0,38,4,5,1
    causes knights to have massive radius to the point its hard to move them near buildings. However the visual radius hasnt changed;the white circle is still the same size.

    switching to division by 100 I found the following is close to what I am looking for;
    up-effect 1,0,38,3,50,2
    up-effect 1,0,38,4,50,2
    producing units that stand a tile apart at the closest

    So bottom line, is there any way to update their visual appearance too? I was thinking there might be a seperate attribute similar to how armour and shown armour works, but I dont see anything like that in the lists. Its going to be pretty weird to try using this in a scenario if you cannot see the different hitboxes. I would like to make it more like Warcraft3 where the units control their own space much better. AoK combat is a chaotic moshpit in comparison.



    By the way, is there some way to modify a units formation capacity? For example I want to re-enable the horde formation for certain military units. I had an AoK game manual from near release, and those early ones still reference with a picture a Horde mode which was removed at release, I think. Villagers still behave this way;they cannot enter military formations and thus cannot be made to stack on top of each other. Thats what I am looking for, preventing military units from stacking via formations. As it is right now, you can get 40 paladins to squeeze through a single tile gap 'somehow'


    (Im guessing the answer to both of the above Qs is full on data modding)

    "Excellent could be any map that has the quality of a ES random map or ES scenario. AoK is an excellent, award winning game. That's where I'd start." -AnastasiaKafka

    "Hard work is evil. Bitmaps are stupid. Working on a scenario for more than one afternoon is stupid. Triggers are stupid. Testing your own scenario is stupid. The world is stupid. You are the Greatest." -Ingo Van Thiel
    BF_Tanks
    Squire
    posted 09-03-19 02:23 PM CT (US)     181 / 186       
    I don't think it's possible to change formations a unit gets, at least from a data editing point. It's possibly tied to the Class, but I have no clue for certain.

    As for their visual hitbox, I don't think UP can change that.

    You're looking for this;


    "Selection Outline Size XYZ" -- but I don't think it's possible to change that with a up-effect. UP-effects can only modify certain attributes, sadly, not all of them.

    Dividing 50 by 100 is right, that would be 0.5 (or "one tile"). 5 is like.. 10 tiles?

    Proud Member of Black Forest Studios
    Co-creator of Silent Evil - Voted Best Multiplayer Scenario of 2009
    and The Seas of Egressa - Voted Best Multiplayer Scenario of 2010

    [This message has been edited by BF_Tanks (edited 09-03-2019 @ 02:25 PM).]

    Tarsiz
    Squire
    posted 09-26-19 01:25 PM CT (US)     182 / 186       
    Hey,

    Thanks for the guide, it feels pretty complete and it's not too hard to get a basic grasp of the concepts.

    I'm currently facing a problem using and up-effect to give a unit the ability of causing trample damage (like a war elephant) and I thought I would ask here.

    I'm trying to give the ability to Joan of Arc to deal trample damage like a war elephant. Using the UP effects, if I understood properly, I need to 1) set the blast attack of Joan of Arc to 2 and 2) set the blast radius of the unit to something greater than 0.

    Knowing that Joan of Arc's ID is 629 I tried the following:

    up-effect 1,0,629,44,2,1 (to set her blast attack to 2)
    up-effect 1,0,629,22,1,1 (to set her blast radius to 1, for war elephants it's 0.5)

    I've also tried up-effect 1,0,629,22,50,2 for the second effect but none of my attempts have worked yet.

    Thoughts?
    BF_Tanks
    Squire
    posted 09-29-19 01:06 PM CT (US)     183 / 186       
    Attribute 44 (BLAST_LEVEL) is set to 2 (Player & Allies) - Joan can only harm allies or her own units in that case. I think you want to set it to 0, so she damages everything.

    Blast damage isn't a value you can adjust, I think it comes from the attack value of the unit. Blast Radius should be all you need.

    Proud Member of Black Forest Studios
    Co-creator of Silent Evil - Voted Best Multiplayer Scenario of 2009
    and The Seas of Egressa - Voted Best Multiplayer Scenario of 2010

    [This message has been edited by BF_Tanks (edited 09-29-2019 @ 01:09 PM).]

    Tarsiz
    Squire
    posted 09-30-19 03:52 AM CT (US)     184 / 186       
    Fair enough, thank you for your answer.
    In case that was not clear I was not trying to adjust the blast "damage" since indeed I could not read anything about it, I just wanted to add a blast "attack" in the same way as war elephants or logistica cataphracts.

    I was mislead by A.G.E which lists the blast attack of war elephants at 2:



    I guess it is not possible to fully reproduce that effect (i.e. war elephant trample damage) then?
    BF_Tanks
    Squire
    posted 10-03-19 05:43 AM CT (US)     185 / 186       
    Huh.. you're right about the Blast Level.

    I tried your up lines and it worked fine for me, seemingly;




    Something I observed: the blast damage is the same on all units in the radius against a melee uni like Joan, so take that into consideration.

    If yours isn't working, check how you've set up the trigger, maybe you're not firing it or the Display Instructions effect is on the wrong timer value?

    Proud Member of Black Forest Studios
    Co-creator of Silent Evil - Voted Best Multiplayer Scenario of 2009
    and The Seas of Egressa - Voted Best Multiplayer Scenario of 2010

    [This message has been edited by BF_Tanks (edited 10-03-2019 @ 05:47 AM).]

    BF_Tanks
    Squire
    posted 10-03-19 09:23 AM CT (US)     186 / 186       
    Alright, some more understanding of 'Blast Level' --

    Thanks for bringing this topic up, because my guide is clearly misinformed. Looking into Blast Level a bit more has revealed some key things about it and the relationship with 'Blast Armor'.
    We don't have a means to change Blast Armor with UP, sadly, but we can look at it in AGE.

    AGE defines Blast Armor as being weighed against another unit's Blast Level. If the attacking unit has lower Blast Level than the recipient's Blast Armor, then the recipient will take damage if they're within the radius.

    It's important to note that there are fundamental differences in how damage is dealt between melee and ranged attacks with a blast radius above 0;

  • Melee has no damage fall-off and doesn't seem to harm allied (including owned) units.
    I used Joan of Arc to hit an enemy wall whilst surrounded by player owned units. All wall units in her Blast radius took full damage, whilst player owned units were fine. This lines up with behaviour we see in typical Trample Damage.

  • Ranged damage is halved when applied to non-targeted units in the blast radius, and harms allied (including owned) units. There might also be some fall-off at play but I'm not sure.
    When I gave a ranged attacker a blast radius, I immediately saw that some attacks that hit would do absolutely 0 damage, whilst a nearby unit would recieve a little damage. In general, hitting the target dealt full damage to it, whilst the blast radius damage was reduced to other units in the radius.



  • Blast Level is also described by AGE as being a range going from 0 to 3;

  • 0 - Affects Units and Resources
  • 1 - Affects Units and Trees
  • 2 - Affects Units only
  • 3 - Affects Target only



  • And, doing a search filter in AGE to find units by 'Blast Attack Level', we see that;

  • 0 - This is held by buildings, most melee units, a few ranged units (Mangudai, Watch Towers, Mamelukes and some heroes), a few projectiles and most GAIA units (resources/dead units/hawks/eye-candy)
  • 1 - This is held exclusively by Trebs, Siege Onagers and the non-chemistry treb projectile.
  • 2 - This is held by all the other Siege (except Scorpions), Hero Trebs, COBRA, cannon-firing ships and units with Trample damage (Catas/Eles).
  • 3 - This is held by most ranged units and most projectiles.



  • A further search on what units have Blast Armor;

  • 0 - Most GAIA (Resources/Eye-Candy Elements), Dead and Projectile Units have this.
  • 1 - Only Trees, Craters and Rugs have this.
  • 2 - Buildings have this.
  • 3 - Living Units have this.



  • Every unit can do Blast Damage, if they have a radius greater than 0.

    Looking at what we now know, we can see the correlations:
    Most living Units will recieve any Blast Damage, at Blast Armor 3. Most Ranged Units have Blast Level 3, meaning they'll only damage their target with Blast Damage. (If they had a radius.)
    Buildings will recieve Blast Damage from only certain units. (Cataphract, Elephants, and most siege.)
    Trees, Craters and Rugs will recieve Blast Damage from Trebs, some units (Mangudai, Mameluke, Towers), Siege Onagers, Melee units and some projectiles.
    Also, this explains why Towers which have Blast Level 1 commonly break Haystacks in Tower Defense scenarios.

    There's a wierd thing happening with Blast Level 4. When testing units with Blast Level 4, all blast damage dealt seemed to be either 5 or 0, irrespective of the unit's attack value. There were also often situations where the damage would sometimes occur to all units in the radius, and sometimes occur to only those closest to the blast center.


    It was also capable of damaging ALL units.

    On a Melee unit, this is the only blast level where the 5-or-0 damage could be treated as a "damage fall-off" as a Joan of Arc (with 17 attack) only does 5 damage in the blast radius.

    It still, however, affects everyone in the radius unlike ranged attacks that have that fall-off, and occasional entire shot immunity.

    This behaviour persists through to Blast Level 8, where we suddenly see Melee units inflicting half their attack damage to units in the Blast Radius, much like typical ranged unit blast behaviour.

    Proud Member of Black Forest Studios
    Co-creator of Silent Evil - Voted Best Multiplayer Scenario of 2009
    and The Seas of Egressa - Voted Best Multiplayer Scenario of 2010

    [This message has been edited by BF_Tanks (edited 10-03-2019 @ 10:02 AM).]

    « Previous Page  1 ··· 4 5 6  Next Page »
    You must be logged in to post messages.
    Please login or register

    Hop to:    

    Age of Kings Heaven | HeavenGames