Fix crash when lastController is null
This commit is contained in:
@@ -611,6 +611,8 @@ MTGCardInstance * MTGCardInstance::changeController(Player * newController,bool
|
|||||||
|
|
||||||
Player * MTGCardInstance::controller()
|
Player * MTGCardInstance::controller()
|
||||||
{
|
{
|
||||||
|
if(!lastController)//if null then set the owner as the lastcontroller, prevents crashes...
|
||||||
|
lastController = owner;
|
||||||
return lastController;
|
return lastController;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user