mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2025-12-17 01:15:52 +01:00
Merge branch 'tower' into development
This commit is contained in:
@@ -26,6 +26,7 @@ import emu.grasscutter.game.managers.SotSManager.SotSManager;
|
||||
import emu.grasscutter.game.props.ActionReason;
|
||||
import emu.grasscutter.game.props.EntityType;
|
||||
import emu.grasscutter.game.props.PlayerProperty;
|
||||
import emu.grasscutter.game.props.SceneType;
|
||||
import emu.grasscutter.game.shop.ShopLimit;
|
||||
import emu.grasscutter.game.managers.MapMarkManager.*;
|
||||
import emu.grasscutter.game.tower.TowerManager;
|
||||
@@ -1041,6 +1042,7 @@ public class Player {
|
||||
@PostLoad
|
||||
private void onLoad() {
|
||||
this.getTeamManager().setPlayer(this);
|
||||
this.getTowerManager().setPlayer(this);
|
||||
}
|
||||
|
||||
public void save() {
|
||||
@@ -1110,6 +1112,10 @@ public class Player {
|
||||
}
|
||||
|
||||
public void onLogout() {
|
||||
// force to leave the dungeon
|
||||
if(getScene().getSceneType() == SceneType.SCENE_DUNGEON){
|
||||
this.getServer().getDungeonManager().exitDungeon(this);
|
||||
}
|
||||
// Leave world
|
||||
if (this.getWorld() != null) {
|
||||
this.getWorld().removePlayer(this);
|
||||
|
||||
Reference in New Issue
Block a user