|
发表于 2008-11-15 20:30:31
|
显示全部楼层
老狼的UI
全局变量单位hero整数n
多人使用的话就用数组
function ck takes nothing returns nothing
local integer a = 1
loop
exitwhen a > 6
call SetMissionHandle( ( "CK" + GetPlayerName(GetTriggerPlayer()) ), ( udg_n + I2S(a) ), UnitItemInSlotBJ(udg_hero, a) )
call UnitRemoveItemFromSlotSwapped( a, udg_hero )
call SetItemVisible( GetLastRemovedItem(), false )
call UnitAddItemSwapped( GetMissionItem(( "CK" + GetPlayerName(GetTriggerPlayer()) ), ( SubStringBJ(GetEventPlayerChatString(), 5, 13) + I2S(a) )), udg_hero )
set a = a + 1
endloop
set udg_n = SubStringBJ(GetEventPlayerChatString(), 5, 13)
call QuestMessageBJ( bj_FORCE_PLAYER[0], bj_QUESTMESSAGE_ALWAYSHINT, ( ( ( "当前为" + GetPlayerName(GetTriggerPlayer()) ) + ( GetHeroProperName(udg_hero) + "的第" ) ) + ( udg_n + "号装备栏" ) ) )
endfunction |
|