Volte6 / GoMud

Public repository for GoMud, a Go based Mud server.
GNU General Public License v3.0
28 stars 4 forks source link

Implement "zombie" status #40

Open Volte6 opened 4 months ago

Volte6 commented 4 months ago

Description

We need a behavior for players disconnecting intentionally or unintentionally, and sometimes during combat. Currently they are immediately despawned, which is easy to exploit.

One goal of this change is to not just be punitive, where it represents a way to oppress players with "more rules", but also introduce something that might be useful feature-wise.

Changes

New Config Value

ZombieSeconds (int) - How long a character stays in game after the player disconnects. They will be essentially an idle player at that point. If they are in a group and have auto attack on etc. they will continue to follow these rules. After this expires, players will despawn, if not in combat. LogoutRounds (int) - How many rounds of meditation before a player officially logs out. This would be to provide sufficient time for something they are engaged in to interrupt it. That way breaking combat and quickly logging out doesn't happen in an exploitive manner. AllowAutoZombie (bool) - Allow players to automatically zombify themselves even when logged in?

Considerations

Zombie Behavior

Zombie Behavior could be interesting, but could also lead to a lot of zombie characters filling up the server. Probably needs some optional limiting factor to prevent abuse, such as attaining a level, having an admin granted permission, an account status flag, etc.

Volte6 commented 3 months ago

Initial implementation will only be supporting zombie players due to disconnect being stuck "AFK" in what action their character was already in. They will be able to reconnect as long as it is within the configuration value of zombie time.