|
local real angle=0
local real dist =300
local integer i=0
local integer a=LoadInteger(udg_HT[2],GetHandleId(udg_company),StringHash("knightlifeboolean"))
loop
exitwhen i>5
set knight =CreateUnit(GetOwningPlayer(me),'hkni',GetUnitX(me)+dist*Cos(angle*180/bj_PI),GetUnitY(me)+dist*Sin(angle*180/bj_PI),angle)
set angle=angle+60
set i=i+1
endloop
难道我哪里写错了吗?创建出来的单位位置够不成正六边形! |
|