Как добавить предмету статы?

  • Автор темы Автор темы qofma
  • Дата начала Дата начала

qofma

Активный
1 Апр 2016
81
0
Подскажите ,куда именно писать доп.атрибуты .Я попытался сам ,не получилось,надеюсь вы поможете мне добавить в этот предмет,допустим доп. магрезист 40.
Код:
	"item_hood_of_defiance_ultimate_datadriven"
{
	// General
	//-------------------------------------------------------------------------------------------------------------
	"BaseClass"				"item_datadriven"
	"ID"							"4013"
	"AbilityBehavior"				"DOTA_ABILITY_BEHAVIOR_NO_TARGET | DOTA_ABILITY_BEHAVIOR_IMMEDIATE"
	"Model"							"models/props_gameplay/red_box.vmdl" 
	"Effect"						"particles/generic_gameplay/dropped_item.vpcf"
	"SpellImmunityType"				"SPELL_IMMUNITY_ALLIES_NO"
	"FightRecapLevel"				"1"
	"AbilityTextureName"			"item_hood_of_defiance_ultimate_datadriven"

	// Casting
	//-------------------------------------------------------------------------------------------------------------
	"AbilityCastRange"				"500"
	"AbilityCastPoint"				"0.0"
	
	// Time		
	//-------------------------------------------------------------------------------------------------------------
	"AbilityCooldown"				"12.0"
	
	// Cost
	//-------------------------------------------------------------------------------------------------------------
	"AbilityManaCost"				"0"
	// Special
	//-------------------------------------------------------------------------------------------------------------
	"AbilitySpecial"
	{
		"01"
		{
			"var_type"				"FIELD_FLOAT"
			"duration"				"2.0"
		}
	}

	"precache"
	{
		"soundfile"	"soundevents/game_sounds_heroes/game_sounds_nevermore.vsndevts"
		"particle"	"particles/units/heroes/hero_omniknight/omniknight_repel_buff.vpcf"
	}

	"OnSpellStart"
	{
		"FireSound"
		{
			"EffectName"		"Hero_Omniknight.Repel"
			"Target"			"CASTER"
		}

		"FireEffect"
		{
			"EffectName"		"particles/units/heroes/hero_omniknight/omniknight_repel_cast.vpcf"
			"EffectAttachType" "follow_origin"
			"Target"      "CASTER"
		}

		"ApplyModifier"
		{
			"Target" 			"CASTER"
			"ModifierName"		"modifier_hood_of_defiance_ultimate_datadriven"
		}
	}

	"Modifiers"
	{
		"modifier_hood_of_defiance_ultimate_datadriven"
		{
			"IsBuff"		"1"
			"IsPurgable"	"0"
			"Duration"		"%duration"
			"EffectName"		"particles/units/heroes/hero_omniknight/omniknight_repel_buff.vpcf"
			"EffectAttachType"	"follow_origin"
			"States"
			{
				"MODIFIER_STATE_MAGIC_IMMUNE"	"MODIFIER_STATE_VALUE_ENABLED"
			}
		}
	}
}
 
Последнее редактирование модератором:
[quote author=qofma link=topic=828.msg3601#msg3601 date=1460219389]
Подскажите ,куда именно писать доп.атрибуты .Я попытался сам ,не получилось,надеюсь вы поможете мне добавить в этот предмет,допустим доп. магрезист 40.
Код:
	"item_hood_of_defiance_ultimate_datadriven"
{
	// General
	//-------------------------------------------------------------------------------------------------------------
	"BaseClass"				"item_datadriven"
	"ID"							"4013"
	"AbilityBehavior"				"DOTA_ABILITY_BEHAVIOR_NO_TARGET | DOTA_ABILITY_BEHAVIOR_IMMEDIATE"
	"Model"							"models/props_gameplay/red_box.vmdl" 
	"Effect"						"particles/generic_gameplay/dropped_item.vpcf"
	"SpellImmunityType"				"SPELL_IMMUNITY_ALLIES_NO"
	"FightRecapLevel"				"1"
	"AbilityTextureName"			"item_hood_of_defiance_ultimate_datadriven"

	// Casting
	//-------------------------------------------------------------------------------------------------------------
	"AbilityCastRange"				"500"
	"AbilityCastPoint"				"0.0"
	
	// Time		
	//-------------------------------------------------------------------------------------------------------------
	"AbilityCooldown"				"12.0"
	
	// Cost
	//-------------------------------------------------------------------------------------------------------------
	"AbilityManaCost"				"0"
	// Special
	//-------------------------------------------------------------------------------------------------------------
	"AbilitySpecial"
	{
		"01"
		{
			"var_type"				"FIELD_FLOAT"
			"duration"				"2.0"
		}
	}

	"precache"
	{
		"soundfile"	"soundevents/game_sounds_heroes/game_sounds_nevermore.vsndevts"
		"particle"	"particles/units/heroes/hero_omniknight/omniknight_repel_buff.vpcf"
	}

	"OnSpellStart"
	{
		"FireSound"
		{
			"EffectName"		"Hero_Omniknight.Repel"
			"Target"			"CASTER"
		}

		"FireEffect"
		{
			"EffectName"		"particles/units/heroes/hero_omniknight/omniknight_repel_cast.vpcf"
			"EffectAttachType" "follow_origin"
			"Target"      "CASTER"
		}

		"ApplyModifier"
		{
			"Target" 			"CASTER"
			"ModifierName"		"modifier_hood_of_defiance_ultimate_datadriven"
		}
	}

	"Modifiers"
	{
		"modifier_hood_of_defiance_ultimate_datadriven"
		{
			"IsBuff"		"1"
			"IsPurgable"	"0"
			"Duration"		"%duration"
			"EffectName"		"particles/units/heroes/hero_omniknight/omniknight_repel_buff.vpcf"
			"EffectAttachType"	"follow_origin"
			"States"
			{
				"MODIFIER_STATE_MAGIC_IMMUNE"	"MODIFIER_STATE_VALUE_ENABLED"
			}
		}
	}
}
Подскажите?
[/quote]
 
Последнее редактирование модератором:
Проверяй
Код:
	"item_hood_of_defiance_ultimate_datadriven"
{
	// General
	//-------------------------------------------------------------------------------------------------------------
	"BaseClass"				"item_datadriven"
	"ID"							"4013"
	"AbilityBehavior"				"DOTA_ABILITY_BEHAVIOR_NO_TARGET | DOTA_ABILITY_BEHAVIOR_IMMEDIATE"
	"Model"							"models/props_gameplay/red_box.vmdl" 
	"Effect"						"particles/generic_gameplay/dropped_item.vpcf"
	"SpellImmunityType"				"SPELL_IMMUNITY_ALLIES_NO"
	"FightRecapLevel"				"1"
	"AbilityTextureName"			"item_hood_of_defiance_ultimate_datadriven"

	// Casting
	//-------------------------------------------------------------------------------------------------------------
	"AbilityCastRange"				"500"
	"AbilityCastPoint"				"0.0"
	
	// Time		
	//-------------------------------------------------------------------------------------------------------------
	"AbilityCooldown"				"12.0"
	
	// Cost
	//-------------------------------------------------------------------------------------------------------------
	"AbilityManaCost"				"0"
	// Special
	//-------------------------------------------------------------------------------------------------------------
	"AbilitySpecial"
	{
		"01"
		{
			"var_type"				"FIELD_FLOAT"
			"duration"				"2.0"
		}
		"02"
		{
			"var_type"	"FIELD_INTEGER"
			"magres" "40"
		}
	}

	"precache"
	{
		"soundfile"	"soundevents/game_sounds_heroes/game_sounds_nevermore.vsndevts"
		"particle"	"particles/units/heroes/hero_omniknight/omniknight_repel_buff.vpcf"
	}

	"OnSpellStart"
	{
		"FireSound"
		{
			"EffectName"		"Hero_Omniknight.Repel"
			"Target"			"CASTER"
		}

		"FireEffect"
		{
			"EffectName"		"particles/units/heroes/hero_omniknight/omniknight_repel_cast.vpcf"
			"EffectAttachType" "follow_origin"
			"Target"      "CASTER"
		}

		"ApplyModifier"
		{
			"Target" 			"CASTER"
			"ModifierName"		"modifier_hood_of_defiance_ultimate_datadriven"
		}
	}

	"Modifiers"
	{
		"modifier_hood_of_defiance_ultimate_datadriven"
		{
			"IsBuff"		"1"
			"IsPurgable"	"0"
			"Duration"		"%duration"
			"EffectName"		"particles/units/heroes/hero_omniknight/omniknight_repel_buff.vpcf"
			"EffectAttachType"	"follow_origin"
			"Properties"
			{
				"MODIFIER_PROPERTY_MAGICAL_RESISTANCE_BONUS"		"%magres"
			}
			"States"
			{
				"MODIFIER_STATE_MAGIC_IMMUNE"	"MODIFIER_STATE_VALUE_ENABLED"
			}
		}
	}
}
 
Последнее редактирование модератором:
[quote author=MRK1 link=topic=828.msg3606#msg3606 date=1460230214]
Проверяй
Код:
	"item_hood_of_defiance_ultimate_datadriven"
{
	// General
	//-------------------------------------------------------------------------------------------------------------
	"BaseClass"				"item_datadriven"
	"ID"							"4013"
	"AbilityBehavior"				"DOTA_ABILITY_BEHAVIOR_NO_TARGET | DOTA_ABILITY_BEHAVIOR_IMMEDIATE"
	"Model"							"models/props_gameplay/red_box.vmdl" 
	"Effect"						"particles/generic_gameplay/dropped_item.vpcf"
	"SpellImmunityType"				"SPELL_IMMUNITY_ALLIES_NO"
	"FightRecapLevel"				"1"
	"AbilityTextureName"			"item_hood_of_defiance_ultimate_datadriven"

	// Casting
	//-------------------------------------------------------------------------------------------------------------
	"AbilityCastRange"				"500"
	"AbilityCastPoint"				"0.0"
	
	// Time		
	//-------------------------------------------------------------------------------------------------------------
	"AbilityCooldown"				"12.0"
	
	// Cost
	//-------------------------------------------------------------------------------------------------------------
	"AbilityManaCost"				"0"
	// Special
	//-------------------------------------------------------------------------------------------------------------
	"AbilitySpecial"
	{
		"01"
		{
			"var_type"				"FIELD_FLOAT"
			"duration"				"2.0"
		}
		"02"
		{
			"var_type"	"FIELD_INTEGER"
			"magres" "40"
		}
	}

	"precache"
	{
		"soundfile"	"soundevents/game_sounds_heroes/game_sounds_nevermore.vsndevts"
		"particle"	"particles/units/heroes/hero_omniknight/omniknight_repel_buff.vpcf"
	}

	"OnSpellStart"
	{
		"FireSound"
		{
			"EffectName"		"Hero_Omniknight.Repel"
			"Target"			"CASTER"
		}

		"FireEffect"
		{
			"EffectName"		"particles/units/heroes/hero_omniknight/omniknight_repel_cast.vpcf"
			"EffectAttachType" "follow_origin"
			"Target"      "CASTER"
		}

		"ApplyModifier"
		{
			"Target" 			"CASTER"
			"ModifierName"		"modifier_hood_of_defiance_ultimate_datadriven"
		}
	}

	"Modifiers"
	{
		"modifier_hood_of_defiance_ultimate_datadriven"
		{
			"IsBuff"		"1"
			"IsPurgable"	"0"
			"Duration"		"%duration"
			"EffectName"		"particles/units/heroes/hero_omniknight/omniknight_repel_buff.vpcf"
			"EffectAttachType"	"follow_origin"
			"Properties"
			{
				"MODIFIER_PROPERTY_MAGICAL_RESISTANCE_BONUS"		"%magres"
			}
			"States"
			{
				"MODIFIER_STATE_MAGIC_IMMUNE"	"MODIFIER_STATE_VALUE_ENABLED"
			}
		}
	}
}
[/quote]
Не робит,ты забыл пихнуть "Attributes" "MODIFIER_ATTRIBUTE_MULTIPLE" ,но я сам не знаю куда надо это пихать,надеюсь на вашу помощь
 
Последнее редактирование модератором:
[quote author=Илья link=topic=828.msg3647#msg3647 date=1460391621]
Читай
[/quote]Там нету,что мне надо,в моём коде пишется ,что это баф ,а не пассивка.Как добавить статы в этот код?
Код:
	"Modifiers"
	{
		"modifier_hood_of_defiance_ultimate_datadriven"
		{
			"IsBuff"		"1"
			"IsPurgable"	"0"
			"Attributes" 		"MODIFIER_ATTRIBUTE_MULTIPLE"
			"Duration"		"%duration"
			"EffectName"		"particles/units/heroes/hero_omniknight/omniknight_repel_buff.vpcf"
			"EffectAttachType"	"follow_origin"
			"Properties"
			{
				"MODIFIER_PROPERTY_MAGICAL_RESISTANCE_BONUS"		"%bonus_magic_resist_percentage"
			}
			"States"
			{
				"MODIFIER_STATE_MAGIC_IMMUNE"	"MODIFIER_STATE_VALUE_ENABLED"
			}
		}
	}
}
 
Последнее редактирование модератором:
Реклама: