Valks-Games / Unity-Transport-Layer-UDP-Model

Learning the new Unity Transport Layer
MIT License
3 stars 0 forks source link

Modular Commands #5

Closed valkyrienyanko closed 4 years ago

valkyrienyanko commented 4 years ago

Modular Commands

Right now all commands are in a switch statement in https://github.com/valkyrienyanko/Prototype/blob/master/Server/Assets/Scripts/Console.cs

It would be nice if they were spread across several files.

Take the following structure layout as an example.

Scripts/
+-- Server.cs
+-- Commands/
|   +-- Kick.cs
|   +-- Exit.cs

Each command should have a name, a usage showing the args syntax, and a description of how to use the command. The commands should be stored in a collection so we can type help commandname to get more info on how to use that command.