Variants of this question include:
While we would love to provide you with a clear and authoritative “yes” or “no” answer to these questions, that is easier said than done:
When you ask one of these questions, you usually have a clear mental image already on how your game should look like – an image that we don't have, because often we know way too little about your project: your plans, your team, your skills (modelling, mapping, scripting, programming, …), your deadlines, etc. Not knowing what you really want and if you're ready to – for example – writing material shaders or making changes to the C++ source code is what makes this question difficult to answer.
However, there is an alternative that is much better than any statement we could make: Familiarize yourself with Cafu, try it yourself, and evaluate if it is right for your needs.
For example, download and run the latest demo. Explore the TechDemo map. Then try making a small map of your own, or edit one of the included maps in the editor. Browse the scripts and source code. If there are problems or questions, ask.
Not only will you become familiar with the Cafu details, you will also be able to form a very competent opinion about Cafu's suitability for your project.
In the development of Cafu, an important consideration is the build process that turns the source code into executable programs. This build process is a challenge in its own right, because it must work
Achieving these goals with Visual Studio solution files on Windows (and possibly Makefiles on Linux) is a maintenance nightmare that borders on the impossible. For these reasons, we have chosen to use SCons as the build system for the Cafu Engine. SCons meets the above requirements, and it can still be used automatically and conveniently from most IDEs and Text Editors.
Alas, we realize that having true Visual Studio project and solution files (and similar native files for other IDEs) would still be nice to have. We therefore started looking into these programs:
These all look very promising, but each has problems of its own, and until today nobody ever finished a complete, working solution. If you would like to help improving the situation, it would be very welcome. Until then, please use one of the solutions described in IDEs and Text Editors.
There is no hard limit built into Cafu, but the general rule is that in the worst case, updates of everyone must be distributed over the network to everyone else. That means that the overall network load (on the server) roughly climbs with the number of players squared.
Fortunately, the Cafu network code is able to cut the network load significantly in many cases:
With these features, Cafu can handle a large number of players in a single level all at the same time. We have demonstrated that connecting 8 clients over the internet is possible without problems (and with some bandwidth left) – and that was several years ago over a slow ISDN (64 kbit/s) Internet connection.
You can clone the Cafu source code repository like this:
> git clone --recursive https://bitbucket.org/cafu/cafu.git Cafu
Also see Getting Started with the Cafu Source Code for more details and https://bitbucket.org/cafu/cafu, where you can browse the repository online, create forks, submit pull requests, and find additional help texts.
This is now explained in its own section in the documentation: See Starting your own Game for details.
While you're developing a script for one of your maps, it can be a very helpful shortcut to reload the map script while the game is running, without interrupting it. This avoids the normally required cycle of leaving and re-starting the map.
As a preparatory step, add a function like this to your map script:
-- This function reloads and runs this script again. -- It is useful for working with and testing the script "online", -- i.e. while the game is running and without reloading the map! function reloadScript() -- Adjust the path in the next line as required! dofile("Games/DeathMatch/Worlds/BPWxBeta.lua"); Console.Print("Reloaded the map script.\n"); end
Then, at the Cafu in-game console, enter
to dynamically reload the script.
In theory, you could combine these two steps into one, using something like
runMapCmd('dofile(“…”)'), but that is even harder to type than the version above, and less flexible. (We realize that the entire
runMapCmd(…) business is not optimal. Suggestions for making this more convenient are welcome.)
Note that if you use this technique, it can be helpful (but is not required) to understand how it works: The map script “lives” inside a Lua state that is initialized together with the map. (The in-game console has an entirely separate Lua state, which is why
runMapCmd(…) is needed.) The above commands essentially run
dofile(…) in the context of the maps Lua state, which in turn re-runs the map script.
There are many available resources regarding 3D engines and related their subjects, both online and offline in the form of traditional books and papers. The following list is neither complete nor up-to-date, but we hope that it serves as a starting point for your own investigations into the matter: