mirror of
https://github.com/Anuken/Mindustry.git
synced 2026-01-26 06:22:17 -08:00
Fixed #2335 (probably)
This commit is contained in:
parent
6ab24ccefd
commit
c4e8fef8d0
1 changed files with 5 additions and 0 deletions
|
|
@ -282,6 +282,11 @@ abstract class UnitComp implements Healthc, Physicsc, Hitboxc, Statusc, Teamc, I
|
|||
controller.updateUnit();
|
||||
}
|
||||
|
||||
//clear controller when it becomes invalid
|
||||
if(!controller.isValidController()){
|
||||
resetController();
|
||||
}
|
||||
|
||||
//do not control anything when deactivated
|
||||
if(deactivated){
|
||||
controlWeapons(false, false);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue