dota吧 关注:4,647,793贴子:155,343,587

回复:诈尸钓鱼帖:龟速直播翻新光环指南

取消只看楼主收藏回复


function WTI takes trigger t returns nothing
call DisableTrigger(t)
set IJ=IJ+1
set QY[IJ]=t
set UY[IJ]=(TimerGetElapsed(M))+60
if IJ>8000 then
call WSI()
endif
endfunction
摧毁触发器t
function WSI takes nothing returns nothing
local integer i=0
if U2==false and SC0==false then
loop
call DisplayTimedTextToPlayer(Player(i),0,0,120,"|c00ff0303An internal checksum has failed|r")
call DisplayTimedTextToPlayer(Player(i),0,0,120,"|c00ff0303This might not be a serious glitch, but it is important for me to get it|r")
call DisplayTimedTextToPlayer(Player(i),0,0,120,"|c00ff0303Please send me the replay for this game to IceFrog@gmail.com|r")
set i=i+1
exitwhen i==12
endloop
endif
endfunction
以上应该是错误的自检程序,出现问题时会给玩家发消息致信IF报告数据
function L13 takes nothing returns boolean
local trigger t=GetTriggeringTrigger()
local integer XII=GetHandleId(t)
local unit JTI=(LoadUnitHandle(HY,(XII),(2)))
local integer YRI=GetUnitAbilityLevel(JTI,1093743946)
call SetUnitAbilityLevel(JTI,1093743947,YRI)
call FlushChildHashtable(HY,(XII))
call WTI(t)
set t=null
set JTI=null
return false
endfunction
设置尸王瘟疫等级等于血肉傀儡等级
简而言之是使用技能后及时注册3个触发器。t3为发动技能效果0.01秒后设置瘟疫技能等级等于血肉傀儡技能等级,t1为进入尸王750范围区域


IP属地:山东55楼2012-07-21 17:24
回复
    楼上发现个问题,function N1I里给t注册的0.03秒事件是周期性的,所以每0.03秒就会触发一次。这样说来似乎是用来使傀儡单位h07Y1向尸王聚集的函数。至于h07Y是什么,貌似是个死亡缠绕模型的马甲,提供视觉效果的。理论上说在这马甲挂了以后尸王会回血的,但我没找见函数
    


    IP属地:山东57楼2012-07-21 18:14
    回复
      2026-08-07 11:44:44
      广告
      不感兴趣
      开通SVIP免广告
      终于找见了……
      elseif MBI(L7I,L8I,N0I,NII)<=MQI then 如果傀儡单位单位和尸王距离小于等于18
      call KillUnit(MPI) 杀死傀儡
      set IK=JTI
      set OK=JRI
      call ExecuteFunc((LoadStr(HY,(XII),(46)))) 执行函数LO3
      function LO3 takes nothing returns nothing
      if IsUnitType(IK,UNIT_TYPE_HERO)==true then
      if LI3(OK)then
      call SetUnitState(OK,UNIT_STATE_LIFE,GetUnitState(OK,UNIT_STATE_LIFE)+GetUnitState(OK,UNIT_STATE_MAX_LIFE)*0.10)
      else
      call SetUnitState(OK,UNIT_STATE_LIFE,GetUnitState(OK,UNIT_STATE_LIFE)+GetUnitState(OK,UNIT_STATE_MAX_LIFE)*0.06)
      endif
      else
      if LI3(OK)then
      call SetUnitState(OK,UNIT_STATE_LIFE,GetUnitState(OK,UNIT_STATE_LIFE)+GetUnitState(OK,UNIT_STATE_MAX_LIFE)*0.03)
      else
      call SetUnitState(OK,UNIT_STATE_LIFE,GetUnitState(OK,UNIT_STATE_LIFE)+GetUnitState(OK,UNIT_STATE_MAX_LIFE)*0.02)
      endif
      endif
      endfunction
      设置生命值给尸王回血


      IP属地:山东58楼2012-07-21 18:21
      回复
        野性驱使
        A03E/1093677893
        AOae 耐久光环
        player,self 玩家单位,自己 (即狼人玩家控制的所有单位)
        function U93 takes nothing returns boolean
        if GetLearnedSkill()==1093677893 and IsUnitIllusion(GetTriggerUnit())==false then
        call U83()
        endif
        return false
        endfunction
        非幻象学习野性驱使
        function U83 takes nothing returns nothing
        local unit X9I=GetTriggerUnit()
        local integer YRI=GetUnitAbilityLevel(X9I,1093677893)
        local unit P4I
        local trigger t
        local integer XII
        if YRI==1 then 如果学习的是一级技能
        set P4I=CreateUnit(GetOwningPlayer(X9I),1697657174,0,0,0) 给狼人的玩家创建一个傀儡
        call MLI(P4I,1093687882) 给傀儡添加命令光环并设置永久性
        call SaveUnitHandle(HY,(GetHandleId(X9I)),(219),(P4I))
        set t=CreateTrigger()
        set XII=GetHandleId(t)
        call TriggerAddCondition(t,Condition(function U73))
        call TriggerRegisterTimerEvent(t,0.2,true)
        call SaveUnitHandle(HY,(XII),(2),(X9I))
        call SaveUnitHandle(HY,(XII),(19),(P4I))
        else
        set P4I=(LoadUnitHandle(HY,(GetHandleId(X9I)),(219)))
        endif
        if YRI==2 then
        call UnitRemoveAbility(P4I,1093687882)
        call MLI(P4I,1093687881)
        elseif YRI==3 then
        call UnitRemoveAbility(P4I,1093687882)
        call UnitRemoveAbility(P4I,1093687881)
        call MLI(P4I,1093687880)
        elseif YRI==4 then
        call UnitRemoveAbility(P4I,1093687882)
        call UnitRemoveAbility(P4I,1093687881)
        call UnitRemoveAbility(P4I,1093687880)
        call MLI(P4I,1093687879)
        endif
        set X9I=null
        set P4I=null
        endfunction
        学习1级技能则创建傀儡,每0.2秒将其设置到狼人的坐标,1级以上根据等级添加、移除傀儡对应的命令光环
        function U73 takes nothing returns boolean
        local trigger t=GetTriggeringTrigger()
        local integer XII=GetHandleId(t)
        local unit P4I=(LoadUnitHandle(HY,(XII),(19)))
        local unit JTI=(LoadUnitHandle(HY,(XII),(2)))
        if P4I!=null and GetUnitTypeId(P4I)==1697657174 then
        if MNI(JTI)==false then
        call SetUnitX(P4I,GetUnitX(JTI))
        call SetUnitY(P4I,GetUnitY(JTI))
        endif
        endif
        set t=null
        set P4I=null
        set JTI=null
        return false
        endfunction
        设置傀儡单位到狼人的坐标
        function MNI takes unit u returns boolean
        return GetUnitTypeId(u)<1 or IsUnitType(u,UNIT_TYPE_DEAD)==true
        endfunction
        function MLI takes unit X9I,integer MMI returns nothing
        call UnitAddAbility(X9I,MMI)
        call UnitMakeAbilityPermanent(X9I,true,MMI)
        endfunction
        以上是两个脸熟函数,前者判断是不是死了,后者加技能并设置永久性
        另外,根据函数推测并根据测试证实,狼人死后在他的死亡地仍有傀儡的命令光环


        IP属地:山东59楼2012-07-21 18:50
        回复

          最后遗言
          A0MC/1093684547
          AOae 耐久光环
          air,enemies,ground,her0,invulnerable,vulnerable
          buffID:B05V
          function O53 takes nothing returns boolean
          if GetLearnedSkill()==1093684547 and IsUnitIllusion(GetTriggerUnit())==false and GetUnitAbilityLevel(GetTriggerUnit(),1093684547)==1 then
          call O43()
          endif
          return false
          endfunction
          非幻象学习1级遗言
          function O43 takes nothing returns nothing
          local unit JTI=GetTriggerUnit()
          local trigger t=CreateTrigger()
          local integer XII=GetHandleId(t)
          call M8I(t,EVENT_PLAYER_UNIT_SPELL_EFFECT)
          call TriggerAddCondition(t,Condition(function O13))
          call SaveUnitHandle(HY,(XII),(2),(JTI))
          set t=CreateTrigger()
          set XII=GetHandleId(t)
          call M8I(t,EVENT_PLAYER_UNIT_DEATH)
          call TriggerAddCondition(t,Condition(function O33))
          call SaveUnitHandle(HY,(XII),(2),(JTI))
          set JTI=null
          set t=null
          endfunction
          创建触发器t,注册任意单位发动技能效果事件,任意单位死亡事件,条件函数O13、O33
          function O13 takes nothing returns boolean
          local unit JRI=GetTriggerUnit()
          local unit JTI=(LoadUnitHandle(HY,(GetHandleId(GetTriggeringTrigger())),(2)))
          local trigger t
          if GetUnitAbilityLevel(GetTriggerUnit(),1110455638)>0 and GetUnitAbilityLevel(GetTriggerUnit(),1093678162)==0 and AB1(GetSpellAbilityId())==false and GetSpellAbilityId()!=1095328363 and GetSpellAbilityId()!=1093678426 and GetSpellAbilityId()!=1093682768 and GetSpellAbilityId()!=1093685593 and GetSpellAbilityId()!=1093678680 and GetSpellAbilityId()!=1093681489 and GetSpellAbilityId()!=1093808472 and GetSpellAbilityId()!=1093808471 and GetSpellAbilityId()!=1093808470 and GetSpellAbilityId()!=1093743191 and GetSpellAbilityId()!=1093678667 and GetSpellAbilityId()!=1097163124 and GetSpellAbilityId()!=1093683801 and GetSpellAbilityId()!=1093682767 and GetSpellAbilityId()!=1093750345 and GetSpellAbilityId()!=1093750089 and GetSpellAbilityId()!=1093751096 and GetSpellAbilityId()!=1093751361 and GetSpellAbilityId()!=1093751126 and GetSpellAbilityId()!=1093808473 and GetSpellAbilityId()!=1093748565 and GetSpellAbilityId()!=1093753177 and OI3(GetSpellAbilityId())==false then
          if IsUnitEnemy(JRI,GetOwningPlayer(JTI))==true and A91(GetSpellAbilityId())==false then
          if((LoadInteger(HY,(GetHandleId((JRI))),((4305))))==1)==false then
          set t=CreateTrigger()
          call TriggerRegisterUnitEvent(t,JRI,EVENT_UNIT_SPELL_ENDCAST)
          call TriggerAddCondition(t,Condition(function O03))
          call SaveUnitHandle(HY,(GetHandleId(t)),(2),(JTI))
          call SaveUnitHandle(HY,(GetHandleId(t)),(17),(JRI))
          set t=null
          endif
          endif
          endif
          set JRI=null
          set JTI=null
          return false
          endfunction
          无比凶悍的条件判定啊。人话如下:
          单位有最后遗言buff,没有标记技能,释放技能不是被过滤的技能,则创建触发器t,给t注册指定单位(就是这个释放不被过滤技能的单位)停止释放技能事件,添加条件O03
          过滤技能如下:
          单位类
          A1S9释放毒咒 A06K腐烂 A1VG巨战木棍 A28Q过载 A1WF定点爆破 A20N中断凤凰冲击 A1Z2指定烈火精灵 A1YY烈日炙烤 A1Z3停止烈日炙烤 A205烈日炙烤移动 A21J收回先祖之魂 A27X隔空取物指向 A24E停止海妖之歌 A2FX收回飞锯 A0MP魔法盾 A2JO火之余烬 A2JL火之余烬指定 A21X雷 A21W冰 A21V火 A21Y元素祈唤 A1GU元素祈唤(A杖) A1NI不稳定化合物 A1MI冰晶爆轰 A1QV斥候变形 A0DY推进 A1WB推进(A杖) A026霜冻之箭 A09V毒性攻击 Ahfa灼热之箭 A0LZ智慧之刃 A0QN沸血之矛 A0OI奥术法球
          物品类
          A0T8臂章关闭 A0T7臂章开启 A28Y迈达斯之手 A14A动力鞋 A1WO 、A269 王者之戒切换 A2KG、A2KE天鹰之戒切换 A1ZI 、A1ZH孤注一掷 A1FQ克敌机先切换 A0TE紫苑 A02W、A2KH刷新球 A2K9林肯法球 Aeat吃树 A0JY魔棒 A1Q8灵魂之戒 Aibk闪烁 A0FO魔瓶 A0H6空瓶 A0H7魔瓶(神符) A12W相位鞋 A1ZW先祖韧鼓 A0B6召唤动物信使 A0JT召唤飞行信使 A0K7奥术鞋 A11F、 A11H、A11G、 A11D、 A0S3、A11E天神下凡 A15W刃甲 A2HQ收割之刃(一个隐藏物品,详见百度) A231远行鞋 A08Y、A08Z、A090、A092、A02O达贡之神力 Aipg净魂之刃(就是散失的净化,什么渣翻译) Aitb显影之尘(我还是觉得显隐之尘翻译更好) A1T7飓风(风杖的) A1QD以太冲击 A19M原力法杖(就是推杖,又见蛋疼翻译) A1AC幽灵药剂(就是魂杖的虚无) Achx变羊(羊刀) A1EW卡德加之洞察烟斗(绿帽子) A017疾风步(洛萨之锋) A1WE幻影斧(远程) A0B8幻影斧 Aixk疯狂面具 A0CK梅肯斯姆 A0JL静电冲击(雷神之锤) A1FO金箍棒切换 Aida玄冥盾牌 A0HB、A0D3、A0DF死灵书 A1FD砍树(压制之刃) A1IO辉耀切换 A1FP撒旦之邪力 A0T9极寒冲击(希瓦的守护) A1MO灵魂释放(影之灵龛) A28D纷争面纱 A0K0奶酪 Aipl小净化药水 Aipr治疗药膏 A02X侦察守卫 Aisw岗哨守卫 A1R5回城卷轴 A206诡计之雾 A2EA致残(阿托斯之棍) A2K1静谧之鞋 A2K7击溃(深渊之刃) A2K4缴械(天堂之戟)
          陈旧类(现在没人有这些技能了,但IF也没优化掉)
          脉冲新星(3个技能,常规A21F、A杖A21G、关闭A21H) A0QY电子咆哮(旧蓝猫) A1RA停止灵魂汲取 A06X脉冲新星 A0AQ脉冲新星(A杖) A24A冰(旧) A24B火(旧) A05Z天神下凡(旧) A0FP法术否定(旧) A2HO 致残(废弃)


          IP属地:山东63楼2012-07-25 11:32
          收起回复

            function AB1 takes integer id returns boolean
            return id==1093808454 or id==1093808455 or id==1093808456 or id==1093751609 or id==1093809217 or id==1093809218 or id==1093751609 or id==1093678667 or id==1093752391 or id==1093810257 or id==1093752646 or id==1093686328 or id==1093686327 or id==1093808206 or id==1093753394 or id==1093753395 or id==1093808181 or id==1093743681 or id==1093809721 or id==1093815111 or id==1093808458 or id==1093810008 or id==1093810265 or id==1093809221 or id==1093753416 or id==1093752655 or id==1093748305 or id==1093686341 or id==1093814863 or id==1093813848 or id==1093684560 or id==1093815109 or id==1093815112 or id==1093815097 or id==1093814860
            endfunction
            function OI3 takes integer id returns boolean
            return id==1093682265 or id==1093752642 or id==1093677622 or id==1093679446 or id==1095263841 or id==1093684314 or id==1093685582 or id==1093685065
            endfunction
            过滤手动法球
            integer EI0=-1
            function AA1 takes nothing returns nothing
            set EI0=EI0+1
            set E00[EI0]=1093753431
            set EI0=EI0+1
            set E00[EI0]=1093681718
            set EI0=EI0+1
            set E00[EI0]=1093684023
            set EI0=EI0+1
            set E00[EI0]=1093686327
            set EI0=EI0+1
            set E00[EI0]=1093686328
            set EI0=EI0+1
            set E00[EI0]=1093742918
            set EI0=EI0+1
            set E00[EI0]=1093742920
            set EI0=EI0+1
            set E00[EI0]=1093742919
            set EI0=EI0+1
            set E00[EI0]=1093742916
            set EI0=EI0+1
            set E00[EI0]=1093686067
            set EI0=EI0+1
            set E00[EI0]=1093742917
            set EI0=EI0+1
            set E00[EI0]=1093743959
            set EI0=EI0+1
            set E00[EI0]=1093814353
            set EI0=EI0+1
            set E00[EI0]=1093808945
            set EI0=EI0+1
            set E00[EI0]=1093814351
            set EI0=EI0+1
            set E00[EI0]=1093677647
            set EI0=EI0+1
            set E00[EI0]=1093679193
            set EI0=EI0+1
            set E00[EI0]=1093679194
            set EI0=EI0+1
            set E00[EI0]=1093679408
            set EI0=EI0+1
            set E00[EI0]=1093679410
            set EI0=EI0+1
            set E00[EI0]=1095331943
            set EI0=EI0+1
            set E00[EI0]=1095332962
            set EI0=EI0+1
            set E00[EI0]=1093683254
            set EI0=EI0+1
            set E00[EI0]=1093751108
            set EI0=EI0+1
            set E00[EI0]=1093751863
            set EI0=EI0+1
            set E00[EI0]=1093744973
            set EI0=EI0+1
            set E00[EI0]=1093747011
            set EI0=EI0+1
            set E00[EI0]=1094936696
            set EI0=EI0+1
            set E00[EI0]=1093810265
            set EI0=EI0+1
            set E00[EI0]=1095328363
            set EI0=EI0+1
            set E00[EI0]=1093748055
            set EI0=EI0+1
            set E00[EI0]=1093677367
            set EI0=EI0+1
            set E00[EI0]=1093683801
            set EI0=EI0+1
            set E00[EI0]=1093682767
            set EI0=EI0+1
            set E00[EI0]=1093683255
            set EI0=EI0+1
            set E00[EI0]=1093681720
            set EI0=EI0+1
            set E00[EI0]=1093752645
            set EI0=EI0+1
            set E00[EI0]=1095333995
            set EI0=EI0+1
            set E00[EI0]=1093753417
            set EI0=EI0+1
            set E00[EI0]=1093681995
            set EI0=EI0+1
            set E00[EI0]=1093683788
            set EI0=EI0+1
            set E00[EI0]=1093748303
            set EI0=EI0+1
            set E00[EI0]=1095328865
            set EI0=EI0+1
            set E00[EI0]=1093683266
            set EI0=EI0+1
            set E00[EI0]=1093682227
            set EI0=EI0+1
            set E00[EI0]=1093682246
            set EI0=EI0+1
            set E00[EI0]=1093682756
            set EI0=EI0+1
            set E00[EI0]=1093743191
            set EI0=EI0+1
            set E00[EI0]=1093743681
            set EI0=EI0+1
            set E00[EI0]=1093748292
            set EI0=EI0+1
            set E00[EI0]=1093749071
            set EI0=EI0+1
            set E00[EI0]=1093677655
            set EI0=EI0+1
            set E00[EI0]=1093809721
            set EI0=EI0+1
            set E00[EI0]=1093815111
            set EI0=EI0+1
            set E00[EI0]=1093748304
            set EI0=EI0+1
            set E00[EI0]=1093686329
            set EI0=EI0+1
            set E00[EI0]=1093751096
            set EI0=EI0+1
            set E00[EI0]=1093750095
            set EI0=EI0+1
            set E00[EI0]=1093810244
            set EI0=EI0+1
            set E00[EI0]=1097163124
            set EI0=EI0+1
            set E00[EI0]=1093684016
            set EI0=EI0+1
            set E00[EI0]=1095331948
            set EI0=EI0+1
            set E00[EI0]=1093683796
            set EI0=EI0+1
            set E00[EI0]=1095331954
            set EI0=EI0+1
            set E00[EI0]=1093677656
            set EI0=EI0+1
            set E00[EI0]=1093751349
            set EI0=EI0+1
            set E00[EI0]=1095332727
            set EI0=EI0+1
            set E00[EI0]=1093808182
            set EI0=EI0+1
            set E00[EI0]=1093753416
            set EI0=EI0+1
            set E00[EI0]=1093813569
            set EI0=EI0+1
            set E00[EI0]=1093815092
            set EI0=EI0+1
            set E00[EI0]=1093815095
            set EI0=EI0+1
            set E00[EI0]=1093815089
            endfunction
            function A91 takes integer id returns boolean
            local integer i=0
            loop
            exitwhen i>EI0
            if E00[i]==id then
            return true
            endif
            set i=i+1
            endloop
            return false
            endfunction
            以上3个函数也是用来过滤技能的,不过也太TM长了吧,还各种重复


            IP属地:山东64楼2012-07-25 11:33
            回复

              function O03 takes nothing returns boolean
              local trigger t=GetTriggeringTrigger()
              local integer XII=GetHandleId(t)
              local unit JTI=(LoadUnitHandle(HY,(XII),(2)))
              local unit JRI=(LoadUnitHandle(HY,(XII),(17)))
              local unit P4I=CreateUnit(GetOwningPlayer(JTI),1697656901,GetUnitX(JRI),GetUnitY(JRI),0)
              local integer YRI=GetUnitAbilityLevel(JTI,1093684547)
              call FlushChildHashtable(HY,(XII))
              call WTI(t)
              if MNI(JTI)==false and MNI(JRI)==false then 脸熟函数MNI,判断死亡的
              call MLI(P4I,1093684307) 脸熟函数MLI,添加技能并设置永久性
              call SetUnitAbilityLevel(P4I,1093684307,YRI)
              call IssueTargetOrder(P4I,"soulburn",JRI)
              set t=CreateTrigger()
              set XII=GetHandleId(t)
              call TriggerAddCondition(t,Condition(function IU3))
              call TriggerRegisterTimerEvent(t,0.01,false)
              call SaveUnitHandle(HY,(GetHandleId(t)),(2),(JTI))
              call SaveUnitHandle(HY,(GetHandleId(t)),(17),(JRI))
              call SaveInteger(HY,(GetHandleId(t)),(5),(YRI))
              endif
              set t=null
              set JTI=null
              set JRI=null
              set P4I=null
              return false
              endfunction
              创建傀儡单位释放灵魂燃烧技能,再创建一个非周期0.01秒时间事件的触发器,条件IU3
              function IU3 takes nothing returns boolean
              local trigger t=GetTriggeringTrigger()
              local integer XII=GetHandleId(t)
              local unit JTI=(LoadUnitHandle(HY,(XII),(2)))
              local unit JRI=(LoadUnitHandle(HY,(XII),(17)))
              local integer YRI=GetUnitAbilityLevel(JTI,1093684547)
              call FlushChildHashtable(HY,(XII))
              call WTI(t)
              if MNI(JTI)==false and MNI(JRI)==false then
              endif
              set t=null
              set JTI=null
              set JRI=null
              return false
              endfunction
              貌似是用来排泄哈希表的


              IP属地:山东65楼2012-07-25 11:34
              回复
                function O33 takes nothing returns boolean
                local trigger t=GetTriggeringTrigger()
                local integer XII=GetHandleId(t)
                local unit JTI=(LoadUnitHandle(HY,(XII),(2)))
                local unit JM1=GetTriggerUnit()
                if IsUnitType(JM1,UNIT_TYPE_HERO)==true and GetUnitTypeId(JM1)!=1211117642 and IsUnitIllusion(JM1)==false and IsUnitInRange(JTI,JM1,850)and MNI(JTI)==false and IsUnitAlly(JTI,GetOwningPlayer(JM1))==false then
                if JTI==GetKillingUnit()then
                set OUI[GetPlayerId(GetOwningPlayer(JTI))]=OUI[GetPlayerId(GetOwningPlayer(JTI))]+2
                call M4I("-2 "+GetObjectName(1848658512),3,JM1,0.023,255,0,0,230)
                call SetHer0Int(JM1,GetHer0Int(JM1,false)-2,true)
                call N1I(JM1,JTI,1747993424,"O23",450)
                else
                set OUI[GetPlayerId(GetOwningPlayer(JTI))]=OUI[GetPlayerId(GetOwningPlayer(JTI))]+1
                call M4I("-1 "+GetObjectName(1848658512),3,JM1,0.023,255,0,0,230)
                call SetHer0Int(JM1,GetHer0Int(JM1,false)-1,true)
                call N1I(JM1,JTI,1747993424,"OO3",450)
                endif
                endif
                set t=null
                set JTI=null
                set JM1=null
                return false
                endfunction
                这个是负责死亡偷智力的。
                条件判断触发单位是英雄,单位不是H00J(地卜分身吧),单位不是幻象,单位在沉默术士850范围内,沉默术士未死亡,单位不是sil的同盟,之后创建漂浮文字、设置死亡单位扣智力、运行函数N1I(之前瘟疫用过的创造飞行马甲的函数)。根据凶手单位是不是sil判断是-1还是-2,同时哈希表存入不同的函数名
                


                IP属地:山东66楼2012-07-25 11:38
                回复
                  2026-08-07 11:38:44
                  广告
                  不感兴趣
                  开通SVIP免广告

                  unction N1I takes unit JTI,unit JRI,integer NOI,string N2I,real MRI returns trigger
                  local trigger t=CreateTrigger() 创建触发器t
                  local integer XII=GetHandleId(t)
                  local real L5I=GetUnitX(JTI)
                  local real L6I=GetUnitY(JTI)
                  local real N3I=GetUnitFacing(JTI) 获得死亡单位X、Y坐标和面向角度
                  call TriggerRegisterTimerEvent(t,0.03,true) 给t注册0.03秒周期事件
                  call TriggerAddCondition(t,Condition(function MSI)) 添加条件函数MSI
                  call SaveReal(HY,(XII),(44),((MRI)*1.0)) 存储实数450
                  call SaveInteger(HY,(XII),(30),(WVI(JRI)))
                  call SaveStr(HY,(XII),(46),(N2I))
                  call SaveInteger(HY,(XII),(43),(WVI(JTI)))
                  call SaveUnitHandle(HY,(XII),(45),(CreateUnit(GetOwningPlayer(JTI),NOI,L5I,L6I,N3I)))
                  给死亡单位的所有者创建单位(一个复仇之魂<投射物>模型的马甲)在死亡单位的X、Y坐标并面向死亡单位的面向角度
                  set CK=t
                  set t=null
                  return CK
                  endfunction
                  function MSI takes nothing returns boolean
                  local trigger t=GetTriggeringTrigger()
                  local integer XII=GetHandleId(t)
                  local integer K0I=(LoadInteger(HY,(XII),(30)))
                  local unit JRI=WHI(K0I)
                  local integer MTI=(LoadInteger(HY,(XII),(43)))
                  local unit JTI=WHI(MTI)
                  local real MRI=(LoadReal(HY,(XII),(44)))
                  local unit MPI=(LoadUnitHandle(HY,(XII),(45)))
                  local real x=GetUnitX(MPI)
                  local real y=GetUnitY(MPI)
                  local real L7I=GetUnitX(JRI)
                  local real L8I=GetUnitY(JRI)
                  local real MQI=MRI*0.03 450*0.03,就是13.5了
                  local real MUI=LQI(x,y,L7I,L8I)
                  local real N0I=x+MQI*Cos(MUI*bj_DEGTORAD)
                  local real NII=y+MQI*Sin(MUI*bj_DEGTORAD)
                  call SetUnitX(MPI,N0I)
                  call SetUnitY(MPI,NII)
                  call SetUnitFacing(MPI,MUI) 设置傀儡单位X、Y坐标为由傀儡单位向sil移动13.5距离,面向sil
                  if MNI(JRI)then 如果sil死亡
                  call KillUnit(MPI)
                  call WGI(K0I)
                  call FlushChildHashtable(HY,(XII))
                  call WTI(t) 排泄变量和哈希表,摧毁触发器t
                  elseif MBI(L7I,L8I,N0I,NII)<=MQI then 如果傀儡单位单位和sil距离小于等于13.5
                  call KillUnit(MPI) 杀死傀儡
                  set IK=JTI
                  set OK=JRI
                  call ExecuteFunc((LoadStr(HY,(XII),(46)))) 执行函数
                  call WGI(K0I)
                  call FlushChildHashtable(HY,(XII))
                  call WTI(t)
                  endif
                  set t=null
                  set JRI=null
                  set JTI=null
                  set MPI=null
                  return false
                  endfunction
                  t的实际效果,让傀儡单位飞向sil,到达后运行函数OO3或O23(根据上面平存储的函数名)


                  IP属地:山东67楼2012-07-25 11:39
                  回复
                    function OO3 takes nothing returns nothing
                    local integer XII=GetHandleId(GetTriggeringTrigger())
                    local unit JTI=OK
                    local real JQI=(LoadReal(HY,(XII),(20)))
                    call SetHer0Int(JTI,GetHer0Int(JTI,false)+1,true)
                    call M4I("+1 "+GetObjectName(1848658512),3,JTI,0.023,0,255,0,230)
                    set JTI=null
                    endfunction
                    +1智力
                    function O23 takes nothing returns nothing
                    local integer XII=GetHandleId(GetTriggeringTrigger())
                    local unit JTI=OK
                    local real JQI=(LoadReal(HY,(XII),(20)))
                    call SetHer0Int(JTI,GetHer0Int(JTI,false)+2,true)
                    call M4I("+2 "+GetObjectName(1848658512),3,JTI,0.023,0,255,0,230)
                    set JTI=null
                    endfunction
                    +2智力
                    


                    IP属地:山东68楼2012-07-25 11:40
                    回复