值物大战僵尸 值物大战僵尸
关注数: 26 粉丝数: 113 发帖数: 5,965 关注贴吧数: 3
木凭,你要的秘法天球代码。 function XA takes nothing returns boolean      local real d      if GetUnitAbilityLevel(GetTriggerUnit(),'B06Y')>0 and GetUnitAbilityLevel(GetEventDamageSource(),'A0OI')>0 and Y7(GetHandleId(GetTriggeringTrigger()),"Source")==GetEventDamageSource()then          call UnitRemoveAbility(GetTriggerUnit(),'B06Y')          set d=.01*(5+GetUnitAbilityLevel(GetEventDamageSource(),'A0OI'))*(GetUnitState(GetEventDamageSource(),UNIT_STATE_MANA)+100)          if(IsUnitType(GetTriggerUnit(),UNIT_TYPE_SUMMONED)or IsUnitIllusion(GetTriggerUnit()))and GetUnitTypeId(GetTriggerUnit())!='n004'and GetUnitTypeId(GetTriggerUnit())!='n018'and GetUnitTypeId(GetTriggerUnit())!='n01C'and GetUnitTypeId(GetTriggerUnit())!='n01G'and GetUnitTypeId(GetTriggerUnit())!='n00U'and GetUnitTypeId(GetTriggerUnit())!='n00Y'and GetUnitTypeId(GetTriggerUnit())!='n00Z'then              set d=d+100*GetUnitAbilityLevel(GetEventDamageSource(),'A0OI')          endif          call eTv("+"+I2S(R2I(d)),1,GetTriggerUnit(),.023,191,64,255,216)          if(GetRandomInt(1,100)<=GetUnitAbilityLevel(GetEventDamageSource(),'A0IF')*10)and(O8(GetHandleId(GetTriggeringTrigger()),"DoneViaSpell")==false)then              call SetUnitState(GetEventDamageSource(),UNIT_STATE_MANA,GetUnitState(GetEventDamageSource(),UNIT_STATE_MANA)+.25*GetUnitState(GetEventDamageSource(),UNIT_STATE_MAX_MANA))              call DestroyEffect(AddSpecialEffectTarget("Abilities\\Spells\\Undead\\ReplenishMana\\ReplenishManaCasterOverhead.mdl",GetEventDamageSource(),"overhead"))          endif          call DisableTrigger(GetTriggeringTrigger())          call gg_DamageTarget(GetEventDamageSource(),GetTriggerUnit(),3,d)          call a7(GetHandleId(GetTriggeringTrigger()))          call gg_DisableTrigger(GetTriggeringTrigger())      endif      return false endfunction function Xb takes nothing returns nothing      local trigger t      local unit m5      local unit p5      if GetTriggerEventId()==EVENT_UNIT_SPELL_EFFECT then          set m5=GetSpellTargetUnit()          set p5=GetTriggerUnit()      else          set m5=GetTriggerUnit()
NAJI要的机枪兵技能代码。 function PLX takes nothing returns boolean return GetLearnedSkill()=='A1FF' and GetUnitAbilityLevel(GetTriggerUnit(),'A1FF')==1 endfunction function PMX takes nothing returns nothing local string PPX=D6V(GetExpiredTimer()) local unit PQX=FAV(PPX,"CamoUnit") local string PSX=D6V(PQX) local real PTX=FKV(PSX,"CamoX") local real PUX=FKV(PSX,"CamoY") local integer PWX=FJV(PSX,"CamoTimer") local integer PYX=FJV(PSX,"CamoDamage") if GetUnitX(PQX)==PTX and GetUnitY(PQX)==PUX then set PWX=PWX+1 if PWX>5 then set PYX=PYX+5*GetUnitAbilityLevel(PQX,'A1FF') if PYX>500 then set PYX=500 endif call M0("+"+I2S(PYX),0.75,PQX,.027,100,100,100,255) endif else set PWX=0 set PYX=0 call UnitRemoveAbility(PQX,'A1FG') call UnitRemoveAbility(PQX,'A1LK') endif if PWX==5 then call UnitRemoveAbility(PQX,'A1LK') call UnitAddAbility(PQX,'A1FG') endif call FOV(PSX,"CamoX",GetUnitX(PQX)) call FOV(PSX,"CamoY",GetUnitY(PQX)) call FXV(PSX,"CamoTimer",PWX) call FXV(PSX,"CamoDamage",PYX) set PQX=null endfunction function PZX takes nothing returns boolean local string P_X=D6V(GetTriggeringTrigger()) return GetAttacker()==FAV(P_X,"CamoUnit") endfunction function P0X takes nothing returns nothing local string P_X=D6V(GetTriggeringTrigger()) local unit PQX=FAV(P_X,"CamoUnit") local string PSX=D6V(PQX) local integer PYX=FJV(PSX,"CamoDamage") if GetEventDamageSource()==PQX then if PYX>0 and GetUnitAbilityLevel(GetEventDamageSource(),'A1FG')>0 then call UnitRemoveAbility(PQX,'A1FG') call DisableTrigger(GetTriggeringTrigger()) call DestroyTrigger(GetTriggeringTrigger()) call UnitDamageTarget(PQX,GetTriggerUnit(),PYX,true,true,ATTACK_TYPE_HERO,DAMAGE_TYPE_DIVINE,WEAPON_TYPE_WHOKNOWS) call M0("+"+I2S(PYX)+"!",3,GetTriggerUnit(),.023,255,0,0,255) endif call UnitRemoveAbility(PQX,'A1FG') call FOV(PSX,"CamoX",0) call FOV(PSX,"CamoY",0) call FXV(PSX,"CamoDamage",0) call FXV(PSX,"CamoTimer",0) endif set PQX=null endfunction function P1X takes nothing returns nothing local string P_X=D6V(GetTriggeringTrigger()) local unit PQX=FAV(P_X,"CamoUnit") local trigger t=CreateTrigger() call TriggerRegisterUnitEvent(t,GetTriggerUnit(),EVENT_UNIT_DAMAGED) call TriggerAddAction(t,function P0X) set P_X=D6V(t) call D9V(P_X,"CamoUnit",PQX) set PQX=null set t=null endfunction function P2X takes nothing returns boolean return GetIssuedOrderId()==OrderId("holdposition") endfunction function P3X takes nothing returns nothing call UnitAddAbility(GetTriggerUnit(),'A1LK') endfunction function P4X takes nothing returns nothing local timer t=CreateTimer() local trigger P5X=CreateTrigger() local trigger P6X=CreateTrigger() local unit PQX=GetTriggerUnit() local real PTX=GetUnitX(PQX) local real PUX=GetUnitY(PQX) local integer PWX=0 local integer PYX=0 local string PPX=D6V(t) local string P_X=D6V(P6X) local string PSX=D6V(PQX) call D9V(PPX,"CamoUnit",PQX) call FOV(PSX,"CamoX",PTX) call FOV(PSX,"CamoY",PUX) call FXV(PSX,"CamoTimer",PWX) call FXV(PSX,"CamoDamage",PYX) call TimerStart(t,1,true,function PMX) call V0X(P6X,EVENT_PLAYER_UNIT_ATTACKED) call TriggerAddCondition(P6X,Condition(function PZX)) call TriggerAddAction(P6X,function P1X) call D9V(P_X,"CamoUnit",PQX) call TriggerRegisterUnitEvent(P5X,PQX,EVENT_UNIT_ISSUED_ORDER) call TriggerAddCondition(P5X,Condition(function P2X)) call TriggerAddAction(P5X,function P3X) set P5X=null set P6X=null set PQX=null set t=null endfunction function JLV takes nothing returns nothing local trigger t=CreateTrigger() call V0X(t,EVENT_PLAYER_HERO_SKILL) call TriggerAddCondition(t,Condition(function PLX)) call TriggerAddAction(t,function P4X) set t=null endfunction
1 下一页