1. Melee Mapping contest #3 - Poll is up! Vote for the best 4v4 melee maps!
    Dismiss Notice
  2. The 30th edition of the Modeling Contest is finally up! The Portable Buildings need your attention, so come along and have a blast!
    Dismiss Notice
  3. We have a new contest going on right now! Join the 11th Music Contest! You are to make a Cinematic modern sound-track for this contest, so come and compete with other people for fun.
    Dismiss Notice

[Feedback] Request Features for JASS and the World Editor

Discussion in 'Patch Discussion' started by TriggerHappy, Aug 23, 2018.

  1. Devalut

    Devalut

    Joined:
    Feb 9, 2009
    Messages:
    404
    Resources:
    0
    Resources:
    0
    Some love for the GUI users please

    Temporary heath triggers:
    * Not adding max health or using mana shield, something akin to anti magic shield but more options! *
    - Add x Temporary health to (triggering unit) for Physical type damage for x seconds.
    - Modify existing Temporary heath for (triggering unit) to x
    - Add X seconds to existing Temporary heath for (triggering unit) to x
    - show/hide Temporary health bar under heath bar

    Modify unit Ability Data values
    - Change (triggering unit) inner fire level 1/X - data - Regeneration Rate/Armor/Duration/STRING to X

    Add Dummy triggers
    - Cast X spell at Location/Target x with (Triggering unit) as Source - (This would remove the need for dummy unit's)
    - Add Buff to (Triggering Unit) and Enable/Disable effect X (I.e. Stun/Poison/Curse/ Using X Ability without need of physical cast, just simply the effect) for X seconds


    Multiple copy selection of units/abilities/buffs for transferring over to another map! or an option to inject multiple items into a map without overwriting other ones.

    @WeirdEditor
    I concur!
     
    Last edited: Dec 22, 2018
  2. MyPad

    MyPad

    Spell Reviewer

    Joined:
    May 9, 2014
    Messages:
    1,109
    Resources:
    2
    Models:
    1
    Icons:
    1
    Resources:
    2
    I suppose that these natives (types) have already been requested, but having these may benefit mapmakers as a whole:

    Code (vJASS):

    // For items
    type itemevent extends eventid

    constant itemevent EVENT_ITEM_CREATED
    constant itemevent EVENT_ITEM_REMOVED

    // For destructables
    type destructableevent extends eventid

    constant destructableevent EVENT_DEST_CREATED
    constant destructableevent EVENT_DEST_REMOVED

    // For the onDamage event
    constant native IsEventDamageAttack takes nothing returns boolean
    constant native IsEventDamageOrb takes nothing returns boolean

    // For the events EVENT_PLAYER_MOUSE_UP and EVENT_PLAYER_MOUSE_DOWN
    type mousebutton extends agent

    native GetTriggerMouseButton takes nothing returns mousebutton

    // An extension to the ability tooltip alteration
    native SetUnitAbilityTooltip takes unit whichUnit, integer abilId, integer level, string tooltip returns nothing
    native SetUnitAbilityExtendedTooltip takes unit whichUnit, integer abilId, integer level, string tooltip returns nothing
    native SetUnitAbilityResearchTooltip takes unit whichUnit, integer abilId, integer level, string tooltip returns nothing

    native GetUnitAbilityTooltip takes unit whichUnit, integer abilId, integer level returns string
    native GetUnitAbilityExtendedTooltip takes unit whichUnit, integer abilId, integer level returns string
    native GetUnitAbilityResearchTooltip takes unit whichUnit, integer abilId, integer level returns string

    // A way to make alterations to the base damage permanent
    native SetUnitBaseDamageEx takes unit whichUnit, integer index, integer base, boolean makePermanent returns nothing

    // More on unit's attack
    type missiletype extends agent

    constant missiletype MISSILE_INSTANT
    constant missiletype MISSILE_NORMAL
    constant missiletype MISSILE_ARTILLERY
    constant missiletype MISSILE_LINE
    constant missiletype MISSILE_BOUNCE

    native SetUnitAttackRange takes unit whichUnit, integer index, real range returns nothing
    native SetUnitAttackMissileType takes unit whichUnit, integer index, missiletype missType returns nothing
    native SetUnitAttackMissileSpeed takes unit whichUnit, integer index, real speed returns nothing
    native SetUnitAttackBounceCount takes unit whichUnit, integer index, integer count returns nothing
    native SetUnitAttackBounceRange takes unit whichUnit, integer index, real range returns nothing
    native SetUnitAttackWeaponType takes unit whichUnit, integer index, weapontype whichWeapon returns nothing

    // Already suggested a lot of times by me, but included for the sake of completeness
    native GetUnitAttackRange takes unit whichUnit, integer index returns real
    native GetUnitAttackMissileType takes unit whichUnit, integer index returns missiletype
    native GetUnitAttackMissileSpeed takes unit whichUnit, integer index returns real
    native GetUnitAttackBounceCount takes unit whichUnit, integer index returns integer
    native GetUnitAttackBounceRange takes unit whichUnit, integer index returns real
    native GetUnitAttackWeaponType takes unit whichUnit, integer index returns weapontype

    native GetUnitDefaultBaseDamage takes unit whichUnit, integer index returns integer

    // On attack-event related natives
    constant unitevent EVENT_UNIT_ATTACK_LAUNCH
    constant unitevent EVENT_UNIT_ATTACK_MISS

    native GetUnitAttackDefaultBackswing takes unit whichUnit, integer index returns real
    native GetUnitAttackDefaultCastpoint takes unit whichUnit, integer index returns real
    native GetUnitAttackBackswing takes unit whichUnit, integer index returns real
    native GetUnitAttackCastpoint takes unit whichUnit, integer index returns real

    // These also affect the speed of the attack animation.
    native SetUnitAttackBackswing takes unit whichUnit, integer index, real backswing returns nothing
    native SetUnitAttackCastpoint takes unit whichUnit, integer index, real castPoint returns nothing

    // These deal with the generated projectile for every ranged attack launched.
    type projectileevent extends eventid
    type projectile extends effect

    constant projectileevent EVENT_PROJECTILE_LAUNCH

    // Upon hitting the target or 60 seconds (based on Nes' tests), EVENT_PROJECTILE_EXPIRE catches the moment projectile objects are to be destroyed.
    constant projectileevent EVENT_PROJECTILE_EXPIRE

    // Returns the generated projectile object.
    constant native GetTriggerProjectile takes nothing returns projectile

    // Allows additional manipulation of the projectile
    native GetProjectileSpeed takes projectile whichProj returns real
    native GetProjectileDamage takes projectile whichProj returns real
    native GetProjectileAttackType takes projectile whichProj returns attacktype
    native GetProjectileDamageType takes projectile whichProj returns damagetype
    native GetProjectileWeaponType takes projectile whichProj returns weapontype
    native GetProjectileTarget takes projectile whichProj returns widget
    native GetProjectileTargetX takes projectile whichProj returns real
    native GetProjectileTargetY takes projectile whichProj returns real
    native GetProjectileTargetZ takes projectile whichProj returns real

    native IsProjectileHoming takes projectile whichProj returns boolean
    native IsProjectileDamageAttack takes projectile whichProj returns boolean
    native GetProjectileOwner takes projectile whichProj returns unit
    native GetProjectileArc takes projectile whichProj returns real

    // If set to 0, the missile will hit 0-seconds after.
    native SetProjectileSpeed takes projectile whichProj, real speed returns nothing
    native SetProjectileDamage takes projectile whichProj, real damage returns nothing
    native SetProjectileAttackType takes projectile whichProj, attacktype atkType returns nothing
    native SetProjectileDamageType takes projectile whichProj, damagetype atkType returns nothing
    native SetProjectileWeaponType takes projectile whichProj, weapontype atkType returns nothing
    native SetProjectileTarget takes projectile whichProj, widget target returns nothing
    native SetProjectileTargetX takes projectile whichProj, real x returns nothing
    native SetProjectileTargetY takes projectile whichProj, real y returns nothing
    native SetProjectileTargetZ takes projectile whichProj, real z returns nothing

    native SetProjectileHoming takes projectile whichProj, boolean homing returns nothing
    // If toAttack is true, then the damage inflicted through the projectile is considered as an attack.
    native SetProjectileDamageAttack takes projectile whichProj, boolean toAttack returns nothing
    native SetProjectileOwner takes projectile whichProj, unit whichUnit returns nothing
    native SetProjectileArc takes projectile whichProj, real arc returns nothing

    // On spell-events
    constant unitevent EVENT_UNIT_SPELL_MISS

    // Model related natives
    // As I am not really verbose with models, these suggestions may be improved upon.

    // Gets the unit's model
    type geoset extends agent
    type rendermodelpart extends agent

    type rendermodel extends handle

    native GetUnitModel takes unit whichUnit returns string
    native GetUnitTextureModel takes unit whichUnit, geoset whichGeoset returns string
    native GetUnitRenderModel takes unit whichUnit returns rendermodel

    native SetUnitModel takes unit whichUnit, string model returns nothing
    native SetUnitModelTexture takes unit whichUnit, geoset whichGeoset, string texturePath returns nothing

    native GetDestructableRenderModel takes destructable whichDest returns rendermodel
    native GetItemRenderModel takes destructable whichDest returns rendermodel

    // Allows one to create a new animation based on these info.
    native RenderModelWriteStart takes rendermodel whichModel returns nothing
    // Clears all in-game generated animations from the write list, preventing them from being written upon a RenderModelWrite call.
    native RenderModelClear takes rendermodel whichModel returns nothing
    // Saves the changes made in-game to the model.
    native RenderModelWrite takes rendermodel whichModel returns nothing

    native GetRenderModelTime takes rendermodel whichModel returns real
    native SetRenderModelTimer takes rendermodel whichModel, real time returns nothing

    // Gets a part, object or event based on the model's info
    native GetRenderModelPart takes rendermodel whichModel, integer index returns rendermodelpart
    // Localized only to the coordinates of the model
    native GetRenderModelPartX takes rendermodel whichModel, rendermodelpart whichPart returns real
    native GetRenderModelPartY takes rendermodel whichModel, rendermodelpart whichPart returns real
    native GetRenderModelPartZ takes rendermodel whichModel, rendermodelpart whichPart returns real

    native SetRenderModelPartX takes rendermodel whichModel, rendermodelpart whichPart, real x returns nothing
    native SetRenderModelPartY takes rendermodel whichModel, rendermodelpart whichPart, real y returns nothing
    native SetRenderModelPartZ takes rendermodel whichModel, rendermodelpart whichPart, real z returns nothing
     
     
  3. Hannibal

    Hannibal

    Joined:
    Apr 25, 2013
    Messages:
    36
    Resources:
    0
    Resources:
    0
    Increasing the Maximum Forces in Scenario Properties to 12 (up from 6) would be helpful and in line with the 24 player increase. Previously you could make 6 teams of 2 but to make 12 teams of 2 would require triggers.
    upload_2018-12-1_2-1-59.png

    Force 12 ftw!
     
  4. Napoqe

    Napoqe

    Joined:
    Jul 7, 2011
    Messages:
    192
    Resources:
    0
    Resources:
    0
    Improvement in Resistance Skin ability, to be able to control via World Editor the abilities that will become immune and reduce duration of debuffs.
    Better manipulation of skills directly from Object Editor (ignoring Gameplay Constants):

    Defend
    Ensnare
    Magic Immunes
    The skills can deactivate
    Can change slow values of the Frost Attack, and also can add option to slow the attack speed.
     
  5. yxq1122

    yxq1122

    Joined:
    Jun 5, 2018
    Messages:
    65
    Resources:
    0
    Resources:
    0
    Add missing natives for Stock UI (very urgent):
    Code (vJASS):

    // Get the id of an item in stock by coordinates.
    native GetItemInStock takes unit whichstock, integer x, integer y returns integer
    // Get the x coordinate of an item in stock by id.
    native GetItemXInStock takes unit whichstock, integer itemid returns integer
    // Get the y coordinate of an item in stock by id.
    native GetItemYInStock takes unit whichstock, integer itemid returns integer
    // Change the item at the specific coordinate of stock.
    native SetItemInStock takes unit whichstock, integer itemid, integer x, integer y returns nothing
    // Swap the postions of items in stock.
    native SwapItemInStock unit whichstock, integer x1, integer y1, integer x2, integer y2 returns nothing
    // Get the icon path of an item in stock.
    native GetItemIconInStock unit whichstock, integer x, integer y returns string
    // Change the icon of an item in stock and returns the old icon.
    native SetItemIconInStock unit whichstock, integer x, integer y, string blpname returns string
     
    I also have a post in the Producer update: natives list thread.
     
    Last edited: Dec 13, 2018
  6. WeirdEditor

    WeirdEditor

    Joined:
    May 10, 2018
    Messages:
    56
    Resources:
    0
    Resources:
    0
    Code (vJASS):
    native BlzUnitHideAbility                          takes unit whichUnit, integer abilId, boolean flag returns nothing
    native BlzUnitDisableAbility                       takes unit whichUnit, integer abilId, boolean flag, boolean hideUI returns nothing
    Please make these two not base on count!!

    Based on count:
    count=1
    UnitHideAbility(.,.,true)-> count--
    UnitHideAbility(.,.,false)-> count++
    if(count==0) unit hides its ability
    else unit reveals its ability​

    A earth man's thinking:
    flag=true
    UnitHideAbility(.,.,true)-> flag=false
    UnitHideAbility(.,.,false)-> flag=true
    if(flag==false) unit hides its ability
    else unit reveals its ability​
     
    Last edited: Dec 11, 2018
  7. Wrda

    Wrda

    Joined:
    Nov 18, 2012
    Messages:
    681
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    I can't comprehend what in the world you're talking about, neither it makes sense.
    If you're talking about using countdown timer for this, then use it since it exists already? Instead of asking to add a timer inside the native.
     
  8. MyPad

    MyPad

    Spell Reviewer

    Joined:
    May 9, 2014
    Messages:
    1,109
    Resources:
    2
    Models:
    1
    Icons:
    1
    Resources:
    2
    @Wrda,

    WeirdEditor meant that the natives should work as most would interpret it, a setter function, instead of a counter-based incremental function.
     
  9. WeirdEditor

    WeirdEditor

    Joined:
    May 10, 2018
    Messages:
    56
    Resources:
    0
    Resources:
    0
    What MyPad understood is what I wanted to say. They should be a simply setter funcitons, like SetPlayAbilityAvailble.

    Code (vJASS):

    UnitAddAbility(hero,'A000',1)
    BlzUnitHideAbility(hero,'A000',true)
    BlzUnitHideAbility(hero,'A000',true)
    BlzUnitHideAbility(hero,'A000',false)//this will not reveal the unit's ability, unless you do it again
    Code (vJASS):

    UnitAddAbility(hero,'A000',1)
    BlzUnitHideAbility(hero,'A000',false)
    BlzUnitHideAbility(hero,'A000',true)//this will not hide the unit's ability,unless you do it again
    Ridiculous?
     
  10. WeirdEditor

    WeirdEditor

    Joined:
    May 10, 2018
    Messages:
    56
    Resources:
    0
    Resources:
    0
    Why not integrate BlzSetUnitMaxHP and BlzSetUnitMaxMana into SetUnitState?
     
  11. Devalut

    Devalut

    Joined:
    Feb 9, 2009
    Messages:
    404
    Resources:
    0
    Resources:
    0
    Projectile handling so that us lower serfs of the GUI world can make fancy projectiles abilities that for instance STOP projectiles like a barrier

    Here's some for thought:
    - Create Projectile at Point using X model, source equal to (Triggering Unit)
    - Modify X projectile Projectile Damage Type
    - Modify X projectile Speed
    - Modify X projectile Model
    - Destroy X projectile
    - Remove X projectile
    - Modify X projectile Damage? - ( i'm not sure if damage is stored in the projectile, but this would be neat)
    - Modify X projectile Animation
    - Modify X Projectile Size
    - Pause X projectile
    - Change X Projectiles target to X unit / Point
    - Point - Position of (Last Created Projectile)
    - Projectile Group (Projectiles in X range)
    - Set Expiration for X Projectile
    - (Last Created Projectile)
    - (Last Projectile Launched) - What it says on the tin
    - (Source of X projectile) - refer's to source of projectile
    - (Projectile source is Spell) Boolean? and it's counter part (Physical attack)
    - (Next Projectile) of (Triggering Unit) - What it says on the tin
    - (Speed of X Projectile) - What it says on the tin
     
  12. Mythic

    Mythic

    Joined:
    Apr 24, 2012
    Messages:
    7,467
    Resources:
    41
    Models:
    29
    Icons:
    1
    Maps:
    3
    Spells:
    6
    Tutorials:
    2
    Resources:
    41
    "Nudge Mode" for terrain editor to use arrow keys for moving the selection, with an option for nudge strength to be relative to zoom level.

    Force 24, please. :]
     
  13. deepstrasz

    deepstrasz

    Map Reviewer

    Joined:
    Jun 4, 2009
    Messages:
    7,871
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Not sure if this thread is only for triggers and stuff but I'm going to write that the Bronze Dragon Roost has the icon of the Red Dragon Roost.
    There is not unique Nether Dragon Roost. It's the one for the Black Dragon, icon and model (soundset too?).



    EDIT: also, is there no trigger to set the stock delay and replenish of mercenaries to a value?



    EDIT 2: the Orc and Undead Transport ships are the same.
     
    Last edited: Jan 9, 2019
  14. Wrda

    Wrda

    Joined:
    Nov 18, 2012
    Messages:
    681
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    It's possible already?
     
  15. Karifean

    Karifean

    Joined:
    Jul 8, 2015
    Messages:
    17
    Resources:
    1
    Maps:
    1
    Resources:
    1
    I'd love being able to change whether an ability is physical, magical or universal in the object editor, and if possible, having a field for Gold/Wood Cost of using it on ALL abilities not just the Goblin Shop's Reveal.
     
  16. Napoqe

    Napoqe

    Joined:
    Jul 7, 2011
    Messages:
    192
    Resources:
    0
    Resources:
    0
    Some things you could do is to have Warcraft 3 support various levels of floors. So, I could do my Medieval Resident Evil better. I did little similar to 1, but with medievel things instead of modern things.
    Ah with that implementation, you could add the camera navigation with W, S, A and D. For easy access to specific places. In Blender I use this, to see if it's correctly aligned the model.
     
  17. MyPad

    MyPad

    Spell Reviewer

    Joined:
    May 9, 2014
    Messages:
    1,109
    Resources:
    2
    Models:
    1
    Icons:
    1
    Resources:
    2
    Adding native support for calling functions below a line would be quite helpful. (Implemented directly by the JASS Virtual Machine)

    In turn, a new annotation above a function might help out those gruesome tasks that may not reach completion without external influence.

    Demo:
    Code (vJASS):

    function foo takes nothing returns nothing
        call bar()
    endfunction

    //# nooplimit
    function bar takes npthing returns nothing
        local integer array I
        loop
            exitwhen I[0] >= 1048576
            set I[0] += 1
        endloop
    endfunction
     
     
  18. WeirdEditor

    WeirdEditor

    Joined:
    May 10, 2018
    Messages:
    56
    Resources:
    0
    Resources:
    0
    ExecuteFunc("bar") is not that slow, I think.
     
  19. MyPad

    MyPad

    Spell Reviewer

    Joined:
    May 9, 2014
    Messages:
    1,109
    Resources:
    2
    Models:
    1
    Icons:
    1
    Resources:
    2
    Perhaps, if looking at most practical applications thereof (GUI initialization, for example)

    Reason behind suggestion is to circumvent the comparatively more costly way of emulating such a behavior, such as a forced trigger evaluation/execution or a force enumeration.

    The no-oplimit notation will effectively prevent repeated virtual thread generation for a repetitive task that is anticipated to cost that much, by bypassing the op-limit with a drawback, it only applies to the function below itself.
     
  20. deepstrasz

    deepstrasz

    Map Reviewer

    Joined:
    Jun 4, 2009
    Messages:
    7,871
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Not a bug or anything. However, spells like Thunder Clap have a wider aggro area of effect than the zone the spell acts upon. Neutral hostile/enemy units sense Thunder Clap from a distance even if they were not hit by the spell. It's annoying in many maps. I'm not sure if this can be changed in the gameplay constants or not or if it is hard-coded.