mirror of
https://github.com/Melledy/Grasscutter.git
synced 2024-11-23 10:21:42 +00:00
Simple sanity check when changing scenes
This commit is contained in:
parent
cf69b61b98
commit
1322f909f3
@ -183,6 +183,10 @@ public class World implements Iterable<GenshinPlayer> {
|
||||
}
|
||||
|
||||
public void transferPlayerToScene(GenshinPlayer player, int sceneId, Position pos) {
|
||||
if (player.getScene().getId() == sceneId) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (player.getScene() != null) {
|
||||
player.getScene().removePlayer(player);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user