state(); if data.hp.val <= 0 { c_deselectunit(id); c_deleteunit(pos.x, pos.y, id); } //depth = x;