player_logout.go 384 B

12345678910111213141516171819202122
  1. package event
  2. type PlayerLogout struct {
  3. ActorId string // actor id
  4. PlayerId int64 // player id
  5. }
  6. func NewPlayerLogout(actorId string, playerId int64) PlayerLogout {
  7. event := PlayerLogout{
  8. ActorId: actorId,
  9. PlayerId: playerId,
  10. }
  11. return event
  12. }
  13. func (PlayerLogout) Name() string {
  14. return PlayerLogoutKey
  15. }
  16. func (p PlayerLogout) UniqueId() int64 {
  17. return p.PlayerId
  18. }