forked from Mirrors/openclonk
Objects: Fixed runtime error in ringmenu
ERROR: division by zero. by: Select(381,179) (obj #143) (Objects.ocd\HUD.ocd\Ringmenu.ocd\Script.c:120)
parent
5df61780d4
commit
d3007f0bb3
|
@ -113,8 +113,11 @@ public func Select(int dx, int dy, bool alt)
|
|||
{
|
||||
var item_count=GetLength(menu_icons);
|
||||
if(!item_count)
|
||||
{
|
||||
if(command_object->Selected(this,nil,alt))
|
||||
Close();
|
||||
return;
|
||||
}
|
||||
|
||||
var distance = Sqrt(dx*dx+dy*dy);
|
||||
|
||||
|
|
Loading…
Reference in New Issue