Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
ziqian zhang
Grasscutter
Commits
b5c27723
Commit
b5c27723
authored
Apr 30, 2022
by
KingRainbow44
Browse files
Move join & quit to player event
parent
f73a713f
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/main/java/emu/grasscutter/game/player/Player.java
View file @
b5c27723
...
...
@@ -21,7 +21,6 @@ import emu.grasscutter.game.inventory.Inventory;
import
emu.grasscutter.game.mail.Mail
;
import
emu.grasscutter.game.props.ActionReason
;
import
emu.grasscutter.game.props.PlayerProperty
;
import
emu.grasscutter.game.shop.ShopInfo
;
import
emu.grasscutter.game.shop.ShopLimit
;
import
emu.grasscutter.game.world.Scene
;
import
emu.grasscutter.game.world.World
;
...
...
@@ -37,8 +36,8 @@ import emu.grasscutter.net.proto.PlayerWorldLocationInfoOuterClass;
import
emu.grasscutter.net.proto.ProfilePictureOuterClass.ProfilePicture
;
import
emu.grasscutter.net.proto.SocialDetailOuterClass.SocialDetail
;
import
emu.grasscutter.net.proto.SocialShowAvatarInfoOuterClass
;
import
emu.grasscutter.server.event.
game
.PlayerJoinEvent
;
import
emu.grasscutter.server.event.
game
.PlayerQuitEvent
;
import
emu.grasscutter.server.event.
player
.PlayerJoinEvent
;
import
emu.grasscutter.server.event.
player
.PlayerQuitEvent
;
import
emu.grasscutter.server.event.player.PlayerReceiveMailEvent
;
import
emu.grasscutter.server.game.GameServer
;
import
emu.grasscutter.server.game.GameSession
;
...
...
src/main/java/emu/grasscutter/server/event/
game
/PlayerJoinEvent.java
→
src/main/java/emu/grasscutter/server/event/
player
/PlayerJoinEvent.java
View file @
b5c27723
package
emu.grasscutter.server.event.
game
;
package
emu.grasscutter.server.event.
player
;
import
emu.grasscutter.game.player.Player
;
import
emu.grasscutter.server.event.Cancellable
;
import
emu.grasscutter.server.event.types.
Game
Event
;
import
emu.grasscutter.server.event.types.
Player
Event
;
public
final
class
PlayerJoinEvent
extends
GameEvent
implements
Cancellable
{
private
final
Player
player
;
public
final
class
PlayerJoinEvent
extends
PlayerEvent
implements
Cancellable
{
public
PlayerJoinEvent
(
Player
player
)
{
this
.
player
=
player
;
}
public
Player
getPlayer
()
{
return
this
.
player
;
super
(
player
);
}
}
src/main/java/emu/grasscutter/server/event/
game
/PlayerQuitEvent.java
→
src/main/java/emu/grasscutter/server/event/
player
/PlayerQuitEvent.java
View file @
b5c27723
package
emu.grasscutter.server.event.
game
;
package
emu.grasscutter.server.event.
player
;
import
emu.grasscutter.game.player.Player
;
import
emu.grasscutter.server.event.types.GameEvent
;
import
emu.grasscutter.server.event.types.PlayerEvent
;
public
final
class
PlayerQuitEvent
extends
GameEvent
{
private
final
Player
player
;
public
final
class
PlayerQuitEvent
extends
PlayerEvent
{
public
PlayerQuitEvent
(
Player
player
)
{
this
.
player
=
player
;
}
public
Player
getPlayer
()
{
return
this
.
player
;
super
(
player
);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment