Abilities Examples:ru

From Valve Developer Community
< Dota 2 Workshop Tools:ru‎ | Scripting:ru
Revision as of 09:09, 14 August 2019 by DDSuper (talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

АОЕ Урон

Данная способность после смерти игрока оставляет под ним лужу которая наносит урон в секунду и вешает дебаф

"creature_acid_spray"
{
    // General
    //-------------------------------------------------------------------------------------------------------------
    "BaseClass"              "ability_datadriven"
    "AbilityBehavior"        "DOTA_ABILITY_BEHAVIOR_AOE | DOTA_ABILITY_BEHAVIOR_PASSIVE"         // тип способности - аое,пассивная
    "AbilityUnitDamageType"  "DAMAGE_TYPE_PHYSICAL"                                              // урон физический
    "AbilityTextureName"     "alchemist_acid_spray"                                              // текстура абилки
    // Casting
    //-------------------------------------------------------------------------------------------------------------
    "AbilityCastPoint"  "0.2"                                    // время каста способности
    "AbilityCastRange"  "900"                                    // дистанция каста
    "OnOwnerDied"                                                // Событие - при смерти героя
    {
        "CreateThinker"                                          // создается лужа
        {
            "ModifierName" "creature_acid_spray_thinker"
            "Target" "CASTER"
        }
    }
    "Modifiers"
    {
        "creature_acid_spray_thinker"
        {
            "Aura" "create_acid_spray_armor_reduction_aura"
            "Aura_Radius" "%radius"
            "Aura_Teams" "DOTA_UNIT_TARGET_TEAM_ENEMY"
            "Aura_Types" "DOTA_UNIT_TARGET_HERO | DOTA_UNIT_TARGET_CREEP | DOTA_UNIT_TARGET_MECHANICAL"
            "Aura_Flags" "DOTA_UNIT_TARGET_FLAG_MAGIC_IMMUNE_ENEMIES"
            "Duration" "%duration"
            "OnCreated"
            {
                "AttachEffect"
                {
                    "EffectName" "particles/units/heroes/hero_alchemist/alchemist_acid_spray.vpcf"
                    "EffectAttachType" "follow_origin"
                    "Target" "TARGET"
                    "ControlPoints"
                    {
                        "00" "0 0 0"
                        "01" "%radius 1 1"
                    }
                }
            }
        }
        "create_acid_spray_armor_reduction_aura"
        {
            "IsDebuff" "1"
            "IsPurgable" "0"
            "EffectName" "particles/units/heroes/hero_alchemist/alchemist_acid_spray_debuff.vpcf"                
            "ThinkInterval" "%tick_rate"
            "OnIntervalThink"
            {
                "Damage"
                {
                    "Type"   "DAMAGE_TYPE_PHYSICAL"
                    "Damage" "%damage"
                    "Target" "TARGET"
                }
            }
            "Properties"
            {
                "MODIFIER_PROPERTY_PHYSICAL_ARMOR_BONUS" "%armor_reduction"
            }
        }
    }
    // Special    
    //-------------------------------------------------------------------------------------------------------------
    "AbilitySpecial"
    {
        "01"
        {
            "var_type"                "FIELD_INTEGER"
            "radius"                "250"
        }
        "02"
        {
            "var_type"                "FIELD_FLOAT"
            "duration"                "16.0"
        }
        "03"
        {
            "var_type"                "FIELD_INTEGER"
            "damage"                "118 128 138 158"
        }
        "04"
        {
            "var_type"                "FIELD_INTEGER"
            "armor_reduction"                "-3 -4 -5 -6"
        }
        "05"
        {
            "var_type"                "FIELD_FLOAT"
            "tick_rate"                "1.0"
        }
    }
}

Пример Orb-атак

Способность имеет автокаст (подобный ледяным стрелам траксы), атакующий герой нанесет 95 ед. чистого урона и будет давать мини баши на 2 секунды.

"orb_ability_example"
{
    "BaseClass"                 "ability_datadriven"
    "AbilityBehavior"           "DOTA_ABILITY_BEHAVIOR_UNIT_TARGET | DOTA_ABILITY_BEHAVIOR_AUTOCAST| DOTA_ABILITY_BEHAVIOR_ATTACK"
    "AbilityUnitTargetTeam"     "DOTA_UNIT_TARGET_TEAM_ENEMY"
    "AbilityUnitTargetType"     "DOTA_UNIT_TARGET_ALL"
    "AbilityCastPoint"          "0.0"
    "AbilityCastRange"          "900"
    "AbilityCooldown"           "0"
    "AbilityManaCost"           "10"
    "AbilitySpecial"
    {
        "01"
        {
            "var_type"          "FIELD_INTEGER"
            "RangeDamage"       "75"
        }
    }
 
    "Modifiers"
    {
        "TestOrb_Modifier"
        {
            "Passive"     "1"
            "IsHidden"    "1"
            "Orb"
            {
                "Priority"          "DOTA_ORB_PRIORITY_ABILITY"
                "ProjectileName"    "particles/units/heroes/hero_sven/sven_spell_storm_bolt.vpcf"
                "CastAttack"        "1"
            }
            "OnOrbFire"
            {
                "SpendMana"
                {
                    "Mana"    "%AbilityManaCost"
                }
            }
            "OnOrbImpact"
            {
                "FireEffect"
                {
                    "EffectName"            "particles/units/heroes/hero_sven/sven_spell_warcry.vpcf"
                    "EffectAttachType"      "attach_hitloc"
                    "Target"                "TARGET"
                }
                "Damage"
                {
                    "Type"          "DAMAGE_TYPE_PURE"
                    "Damage"        "%RangeDamage"
                    "Target"
                    {
                        "Center"    "TARGET"
                        "Teams"     "DOTA_UNIT_TARGET_TEAM_ENEMY"
                        "Type"      "DOTA_UNIT_TARGET_ALL"
                        "Radius"    "275"
                    }
                }
                "Stun"
                {
                    "Duration"      "2"
                    "Target"
                    {
                        "Center"    "TARGET"
                        "Teams"     "DOTA_UNIT_TARGET_TEAM_ENEMY"
                        "Type"      "DOTA_UNIT_TARGET_ALL"
                        "Radius"    "275"
                    }
                }
            }
        }
    }
}

Простая аура

Простая аура, которая в радиусе 900 вокруг героя будет снижать противникам урон на 50%

 "TestSysAura"
 {
  "BaseClass" "ability_datadriven"
  "AbilityBehavior" "DOTA_ABILITY_BEHAVIOR_AURA | DOTA_ABILITY_BEHAVIOR_PASSIVE"
  "AbilityUnitTargetTeam" "DOTA_UNIT_TARGET_TEAM_ENEMY"
  "AbilityUnitTargetType" "DOTA_UNIT_TARGET_ALL"
  "AbilityTextureName" "alchemist_acid_spray"
  "MaxLevel" "1"
 
  "AbilityCastPoint"    "0.0"
  "AbilityCastRange"    "500"
  "AbilityCooldown"    "0"
  "AbilityManaCost"    "0"
 
  "AbilitySpecial"
  {
   "01"
   {
    "var_type" "FIELD_INTEGER"
    "Range" "500"
   }
  }
 
  "Modifiers"
  {
   "TestSysAura_Modifier"
   {
    "Passive" "1"
    "IsHidden" "1"
    "Aura" "TestSysAura_FixAttackPercent"
    "Aura_Radius" "%Range"
    "Aura_Teams" "DOTA_UNIT_TARGET_TEAM_ENEMY"
    "Aura_Types" "DOTA_UNIT_TARGET_ALL"
   }
 
   "TestSysAura_FixAttackPercent"
   {
    "IsDebuff" "1"
    "IsPurgable" "0"
    "Properties"
    {
     "MODIFIER_PROPERTY_DAMAGEOUTGOING_PERCENTAGE" "-50"
    }
   }
  }
 }

--Blood_Hunter (talk) 21:14, 28 December 2015 (UTC)

Item Examples

"item_shard_immortal"
	{
		"BaseClass"             		"item_datadriven"
		"AbilityBehavior"				"DOTA_ABILITY_BEHAVIOR_UNIT_TARGET"
		"AbilityUnitTargetTeam"			"DOTA_UNIT_TARGET_TEAM_FRIENDLY"
		"AbilityUnitTargetType"			"DOTA_UNIT_TARGET_CREEP"
		"SpellImmunityType"				"SPELL_IMMUNITY_ENEMIES_NO"
		"ItemShareability" "ITEM_NOT_SHAREABLE"	
		"AbilityTextureName"			"shardimmortality"
		"Model"							"models/props_gameplay/red_box.vmdl" 
		"Effect"						"particles/generic_gameplay/dropped_item.vpcf"
		"AbilityCooldown"	"80"
		"AbilityCastRange"	"880"
		"ItemDisassembleRule"			"DOTA_ITEM_DISASSEMBLE_ALWAYS"
		"ItemQuality"	"epic"
		"ItemCost"		"6670"
		"ItemDeclarations"				"DECLARE_PURCHASES_TO_TEAMMATES | DECLARE_PURCHASES_IN_SPEECH | DECLARE_PURCHASES_TO_SPECTATORS"
		"AbilitySpecial"
		{
			"01"
			{
				"var_type"			"FIELD_FLOAT"
				"duration"		"14"
			}
			"02"
			{
				"var_type"	"FIELD_INTEGER"
				"projectile_speed"	"1000"
			}
		}
		"OnSpellStart"
		{
			"TrackingProjectile"
			{
				"Target"           	"TARGET"
				"EffectName"		"particles/units/heroes/hero_abaddon/abaddon_death_coil.vpcf"
				"Dodgeable"			"1"
				"MoveSpeed"        	"%projectile_speed"
				"SourceAttachment"	"DOTA_PROJECTILE_ATTACHMENT_ATTACK_1"
			}
            "SpendCharge"
            {}
		}
		"OnProjectileHitUnit"
		{
			"DeleteOnHit"	"1"
			"Damage"
			{
				"Target"		"TARGET"
				"Type"			"DAMAGE_TYPE_MAGICAL"
				"Damage"		"300000"
			}
			"FireSound"
			{
				"EffectName" "DOTA_Item.BlackKingBar.Activate"
				"Target" "CASTER"
			}
			"ApplyModifier"
			{
				"ModifierName"	"modifier_shard_active"
				"Target" 		"CASTER"
			}
		}
		"Modifiers"
		{
			"modifier_shard_active"
			{
				"Passive"			"0"
				"IsBuff"	"1"
				"Duration"	"%duration"
				"TextureName"	"shardactivated"
				
				"EffectName"            	"particles/items_fx/black_king_bar_avatar.vpcf"
				"EffectAttachType"      	"follow_origin"
				"Target"	"CASTER"
				
				"States"
				{
					"MODIFIER_STATE_ATTACK_IMMUNE"		"MODIFIER_STATE_VALUE_ENABLED"
				}
				"Properties"
				{
					"MODIFIER_PROPERTY_ABSOLUTE_NO_DAMAGE_PHYSICAL" "1"
					"MODIFIER_PROPERTY_ABSOLUTE_NO_DAMAGE_MAGICAL" "1"
					"MODIFIER_PROPERTY_ABSOLUTE_NO_DAMAGE_PURE" "1"
				}
			}
		}
	}

--DDSuper (talk) 12:05, 14 August 2019 (UTC)