From e16bdd07e1abb1b6705f83bd3e1e1529fc142d8b Mon Sep 17 00:00:00 2001 From: Ryan Liptak Date: Wed, 4 Sep 2013 11:37:00 -0700 Subject: [PATCH] Added some file/dir guidelines --- README.md | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index af368691..4f8112f4 100644 --- a/README.md +++ b/README.md @@ -18,13 +18,23 @@ We will be using the branching model laid out here: http://nvie.com/posts/a-succ ## Code +* Avoid making changes in the base Source engine files; always try to move those changes into a FF-specific source file that derives from the base class. + ### Syntax -#### Variable, Function, File Names and Directory Structure +#### Variable and Function Names * __TODO__ Decide on a naming convention * Always make variable and function names as descriptive as possible (if 'i' stands for 'currentPlayerIndex' then use 'currentPlayerIndex') +#### File Names and Directory Structure + +* Always put FF code files in the src/game//ff/ directory. + * __TODO__ Decide on a subdirectory scheme +* Always prefix Fortress Forever code files with ff_ +* Add a secondary prefix depending on the usage of the file; for client-only files, use cl\_; for server-only files, use sv\_; for shared files, use sh\_ + * Example: the "player" source files would be named: ff\_cl\_player, ff\_sv\_player, and ff\_sh\_player + ### Adding/Removing Files Solution and makefiles are no longer stored on the repo, they are generated using [VPC](https://developer.valvesoftware.com/wiki/Valve_Project_Creator). To add/remove files from the project, you must edit the __game/client/client_ff.vpc__ and/or __game/server/server_ff.vpc__ files and then execute __createallprojects(.bat)__ in the __src/__ directory. To remove a non-FF-specific file from the project (like HL2DM files), add exactly what you would to add the file (or copy the line from the .vpc that includes it), but put a - before "$File".