https://odamex.net/w/api.php?action=feedcontributions&user=Voxel&feedformat=atomOdaWiki - User contributions [en]2024-03-28T11:06:43ZUser contributionsMediaWiki 1.24.1https://odamex.net/w/index.php?title=Frequently_Asked_Questions&diff=3250Frequently Asked Questions2008-07-18T20:33:21Z<p>Voxel: /* When will Odamex be released? */</p>
<hr />
<div>Do you have a question you feel is worthy of the FAQ? Send a private message to [http://odamex.net/boards/index.php?action=pm;sa=send;u=1 Manc] with your question (and answer if you have it).<br />
<br />
== General Questions ==<br />
=== Why Odamex? ===<br />
Odamex follows the philosophy of the free software movement. We feel that as a community we can make our software better. Since we feel so strongly about this belief we have chosen to release the Odamex source code under the GNU GPLv2 [[license]].<br />
<br />
=== Will Odamex support advanced features? ===<br />
That depends entirely on what you consider advanced features. Odamex strives for full Boom compatibility and also has other enhancements over regular Doom such as mouselook and jumping (which can both be turned off on the server level). Due to license conflicts, all Hexen source had to be removed or replaced.<br />
<br />
== Requirements ==<br />
===What platforms can Odamex run on?===<br />
Odamex has been tested and has been confirmed to compile and run on the following operating systems and chipsets:<br />
<br />
====Intel x86====<br />
* Windows NT family (Vista, XP, 2000, 2003)<br />
* Windows 9x family (98, 95, Me)<br />
* Linux<br />
* FreeBSD<br />
* OpenBSD<br />
* Solaris<br />
* Mac OS X<br />
<br />
====PowerPC====<br />
* Mac OS X<br />
* Linux<br />
<br />
====SPARC====<br />
* Solaris<br />
<br />
If your operating system and chipset combination is not listed above, however, this does not necessarily mean that Odamex will not run on it. Odamex was designed with portability in mind, and it may very well run on your favorite system and we may not even know it. If you can get Odamex to compile and run on an operating system/chipset combination not listed here, please [[Credits | let us know]].<br />
<br />
=== Are there any set hardware requirements? ===<br />
Not really. Given the software requirements being fulfilled, Odamex has run on pretty much everything we've thrown at it. If you can find a hardware combination that fulfills the software requirements but that Odamex will not run on, let us know.<br />
<br />
=== What data files are required? ===<br />
Odamex requires a resource file from Doom or Doom 2 in order to play online. The most common resource files needed to play are:<br />
<br />
{|border=1<br />
<br />
|-<br />
! Resource !!Title !!Version !!Availability<br />
<br />
|-<br />
|DOOM1.WAD<br />
|[http://www.idsoftware.com Doom 1: Knee-Deep in the Dead]<br />
|v1.9<br />
|style="color:orange"|<br />
shareware<br />
<br />
|-<br />
|DOOM.WAD<br />
|[http://www.idsoftware.com Ultimate Doom]<br />
|v1.9<br />
|style="color:red"|<br />
commercial<br />
<br />
|-<br />
|DOOM2.WAD<br />
|[http://www.idsoftware.com Doom II]<br />
|v1.9<br />
|style="color:red"|<br />
commercial<br />
<br />
|-<br />
|TNT.WAD<br />
|[http://www.idsoftware.com Final Doom: TNT Evilution]<br />
|v1.9<br />
|style="color:red"|<br />
commercial<br />
<br />
|-<br />
|PLUTONIA.WAD<br />
|[http://www.idsoftware.com Final Doom: The Plutonia Experiment]<br />
|v1.9<br />
|style="color:red"|<br />
commercial<br />
<br />
|-<br />
|FREEDOOM.WAD<br />
|[http://freedoom.sourceforge.net FreeDoom]<br />
|v0.6.2<br />
|style="color:green"|<br />
free<br />
<br />
|}<br />
<br />
The version number is important. There are several versions of most of these resource files floating around, and resources from one version may not work with another, so for consistencies sake the latest version is assumed. If you have a copy of Doom Collectors Edition or a version of Ultimate Doom or Doom 2 that is for Windows 95, then you are using the latest version of those resource files. If you have a copy of Doom or Doom 2 for DOS, please patch your resource file to the latest version. <br />
<br />
The following are free to download and use:<br />
<br />
* [http://freedoom.sourceforge.net FreeDoom] - "The Freedoom project aims to create a complete Doom-based game which is Free Software."<br />
* [ftp://ftp.idsoftware.com/idstuff/doom/doom19s.zip Doom Shareware] - "The wad that started it all!" (v1.9)<br />
<br />
== Playability ==<br />
=== What's up with this? I can't connect to some of the servers! ===<br />
Updates to the codebase are frequent. There are some servers which are running out-of-date versions of Odamex, some that are running the latest public release of Odamex, and some that are running SVN versions of Odamex. We suggest that all servers and clients run the latest public (non-SVN) release of Odamex unless they are specificly marked as development servers. If you see someone running an older version, please contact the server administrator.<br />
<br />
=== Movement seems to be jerky. Watching people move from one place to another is like watching a slideshow! ===<br />
Pardon our mess. =) As Odamex is still in development, we are still working on the netcode, and trying to find the best combination of smooth gameplay, reliability and exploit prevention. However, as you can probably tell, it's not quite there yet. Rest assured, as Odamex's development continues, the quality of the netcode will continue to improve until it is considered acceptable.<br />
<br />
=== There seems to be some weird behavior in general. Odamex acts funny/disconnects me unexpectedly/crashes/other bad things. ===<br />
Bugs, unfortunately, are a real and present part of software development. Odamex is no exception. The good news, however, is that you - yes you - regardless of software development or prior experience, can help us track down and fix these bugs. Please read the section on [[Bugs]] for more information on how you can help.<br />
<br />
=== Help! Everyone moves too fast and I get killed within seconds! ===<br />
Please read the article about [[gameplay]] for a short introduction to Doom's very unique style of Deathmatch.<br />
<br />
=== I am a veteran doom2.exe player. What does Odamex offer me? ===<br />
With the default server configuration, Odamex offers a client/server multiplayer environment that closely emulates the standard gameplay mechanics created by id Software back in 1993 with the initial release of Doom. <br />
<br />
=== I love enhanced gameplay and features. What does Odamex offer me? ===<br />
Players who prefer an enhanced experience to Doom can play in teamplay modes, such as Team Deathmatch and Capture the Flag. They also have the option to jump and to use freelook to guide their vertical aiming on servers which allow it (see [[allowfreelook]] and [[allowjump]]).<br />
<br />
=== How do I record and/or playback Demo files? ===<br />
See the [[recordvanilla]] console command<br />
<br />
== Security ==<br />
=== What is being done about the security of Odamex? ===<br />
* Multiple master support has been added to protect our network<br />
* All important communication paths have challenge/response spoof protection<br />
* [[rcon_password]] uses MD5 digest so that passwords are not sent in plain text<br />
=== How will cheaters be dealt with? ===<br />
See the [[Cheating|cheating]] page.<br />
<br />
== Development ==<br />
=== When will Odamex be released? ===<br />
There is currently no definitive date for a release. However, you can catch up on Odamex progress by reading the [[development roadmap]] and viewing the [http://odamex.net/changelog.php changelog].<br />
<br />
=== I want to contribute to Odamex! What can I do to help? ===<br />
There are many things you can do to contribute to Odamex. You could help by reporting [[bugs]] or by spreading the word around to your friends. If you are a programmer you can submit [[patches]] to the development team for possible inclusion in the next revision.<br />
<br />
=== I found a bug! What should I do? ===<br />
See [[Bugs]] for more information.<br />
<br />
== Misc ==<br />
=== What does the name 'Odamex' mean? ===<br />
The word Odamex is not necessarily an acronym. It is not represented as such anywhere in the application or this website. However, it was originally thought of as such, so included below are some ideas of what it could be:<br />
<br />
* What fraggle says when he is trying to get X working in Linux. "<fraggle> oh, damn X!"<br />
* "Oh! Yes! Fur!" as read in Russian<br />
* Online Doom Multiplayer EXperience</div>Voxelhttps://odamex.net/w/index.php?title=Subversion&diff=3249Subversion2008-07-18T20:32:17Z<p>Voxel: /* Guidelines for maintainers */</p>
<hr />
<div>[[Image:Commits_group_multi_date_graph_2027.png|thumb|Graph of svn activity up to revision 2027, taken 14/11/06.]]<br />
<br />
== I don't feel like reading this whole document. How do I obtain and compile Odamex from Subversion? ==<br />
Following is the cheat-sheet command to build and run odamex from svn on a typical *nix system. This command is not guaranteed to work, in fact it is more likely to fail, you should not use it unless you understand what it does.<br />
<br />
<pre>cd; svn co http://odamex.net/svn/root/ odamex; cd odamex/trunk; make && ./odamex</pre><br />
<br />
== What is Subversion? ==<br />
<br />
Subversion is the current version control repository used to maintain the Odamex source code. In layman's terms, it allows multiple people to be working on the same project at the same time while giving those same people the facilities to recognize collisions between two contributors code.<br />
<br />
== How do I access Odamex's Subversion respository? ==<br />
<br />
Odamex's subversion repository can be accessed using the following URL:<br />
<br />
<pre>http://odamex.net/svn/root/</pre><br />
<br />
== What is Odamex's Subversion access policy? ==<br />
<br />
Read-only access to Odamex's Subversion repository is public, meaning that anyone can checkout the source for their own purposes, including modification and compilation. However, further repository access, such as Commit access, is restricted based on our [[Policy]]. If you wish to contribute to Odamex, please send a [[patch]] to one of the indicated [[MAINTAINERS]]. Those that contribute considerable time to improve the Odamex source may be granted full or partial access.<br />
<br />
Generally, the [[Policy|project manager(s)]] will administrate this access with the guidance of the lead coder(s). Inactive accounts will tend to get frozen or disabled after a certain length of time.<br />
<br />
== How do I use a subversion client? ==<br />
<br />
This depends on the subversion client you happen to be using. However, there are some terms that you should recognize that are consistant between clients.<br />
<br />
===Checkout===<br />
The process of '''checking out''' means that you connect to the subversion server and it downloads a revision of the code you specify and places it into a newly created subversion filesystem on your local hard drive. By default, the HEAD(latest) revision is the one that is checked out, and probably the one that you are most interested in.<br />
<br />
This is how you check out from the command line:<br />
<br />
<pre>svn checkout <server name> <destination directory></pre><br />
<br />
===Update===<br />
Once you check out a revision of odamex's source code, your local version of the code stays that way. If a newer version of the code comes out, you have two options. You can either check out a new version of the code into a seporate directory, or you can '''update''' the existing code that you already have. Note that any changes you have made to your local copy are kept, and not discarded, and if the version you download from the server collides with any of your changed files, subversion will tell you this, and you must handle the conflict between your local copy and the server's repository manually, usually through a revert, or by creating a new local copy so you don't lose your hard work..<br />
<br />
This is how you update from the command line:<br />
<br />
<pre>svn update <local directory></pre><br />
<br />
Note that you do not need to specify the server, as subversion remembers the server where your local copy originated from.<br />
<br />
To get a specific revision, use the "-r" parameter.<br />
<br />
==What Subversion clients are avalable?==<br />
There are many, many subversion clients avalable:<br />
* [http://subversion.tigris.org/ Subversion]: Command Line client for multiple platforms.<br />
* [http://tortoisesvn.tigris.org/ TortiseSVN]: Windows Explorer extension for Windows.<br />
* [http://rapidsvn.tigris.org/ RapidSVN]: wxWidgets based GUI client for multiple platforms.<br />
<br />
== How is Odamex's repository organized ==<br />
Each branch keeps an entire odamex source tree.<br />
<br />
* '''[http://www.odamex.net/svn root]'''<br />
** '''trunk''' - Bleeding-edge development, expect things to break often<br />
** '''branches'''<br />
*** '''ogl_hack''' - A very experimental attempt at creating an OpenGL-based renderer for Odamex<br />
*** other temporary branches may be created or destroyed<br />
** tags<br />
*** Each stable and development release is tagged. This is starting with 0.4 and will be back-tagged for prior releases.<br />
<br />
== How can I be notified when the repository updates? ==<br />
<br />
Any changes to our svn repository are reported in:<br />
* [http://odamex.net/changelog.php?count=100 The Odamex Changelog]<br />
* [[IRC|The Odamex IRC Channel]] by the odasvn bot.<br />
<br />
== Guidelines for maintainers ==<br />
<br />
* Do<br />
** Regularly update your working copy<br />
** Commit individual improvements and corrections to the existing code<br />
** Separate your commits semantically<br />
** Make an informative comment with each commit<br />
** Mention related bugs and revisions (see [http://odamex.net/changelog.php?count=100 changelog] for examples)<br />
** Seek comments on bugzilla and forum before making major changes<br />
** Test your changes before every commit<br />
* Do not<br />
** Commit broken code to trunk or stable<br />
** Commit untested code to stable<br />
** Make giant monolithic commits<br />
** Make major changes without consulting maintainers<br />
** Make frivolous commits<br />
** Overwrite other people's recent work without asking them<br />
** Change EOL modes of files, All files should be LF</div>Voxelhttps://odamex.net/w/index.php?title=Subversion&diff=3248Subversion2008-07-18T20:31:44Z<p>Voxel: /* How can I be notified when the repository updates? */</p>
<hr />
<div>[[Image:Commits_group_multi_date_graph_2027.png|thumb|Graph of svn activity up to revision 2027, taken 14/11/06.]]<br />
<br />
== I don't feel like reading this whole document. How do I obtain and compile Odamex from Subversion? ==<br />
Following is the cheat-sheet command to build and run odamex from svn on a typical *nix system. This command is not guaranteed to work, in fact it is more likely to fail, you should not use it unless you understand what it does.<br />
<br />
<pre>cd; svn co http://odamex.net/svn/root/ odamex; cd odamex/trunk; make && ./odamex</pre><br />
<br />
== What is Subversion? ==<br />
<br />
Subversion is the current version control repository used to maintain the Odamex source code. In layman's terms, it allows multiple people to be working on the same project at the same time while giving those same people the facilities to recognize collisions between two contributors code.<br />
<br />
== How do I access Odamex's Subversion respository? ==<br />
<br />
Odamex's subversion repository can be accessed using the following URL:<br />
<br />
<pre>http://odamex.net/svn/root/</pre><br />
<br />
== What is Odamex's Subversion access policy? ==<br />
<br />
Read-only access to Odamex's Subversion repository is public, meaning that anyone can checkout the source for their own purposes, including modification and compilation. However, further repository access, such as Commit access, is restricted based on our [[Policy]]. If you wish to contribute to Odamex, please send a [[patch]] to one of the indicated [[MAINTAINERS]]. Those that contribute considerable time to improve the Odamex source may be granted full or partial access.<br />
<br />
Generally, the [[Policy|project manager(s)]] will administrate this access with the guidance of the lead coder(s). Inactive accounts will tend to get frozen or disabled after a certain length of time.<br />
<br />
== How do I use a subversion client? ==<br />
<br />
This depends on the subversion client you happen to be using. However, there are some terms that you should recognize that are consistant between clients.<br />
<br />
===Checkout===<br />
The process of '''checking out''' means that you connect to the subversion server and it downloads a revision of the code you specify and places it into a newly created subversion filesystem on your local hard drive. By default, the HEAD(latest) revision is the one that is checked out, and probably the one that you are most interested in.<br />
<br />
This is how you check out from the command line:<br />
<br />
<pre>svn checkout <server name> <destination directory></pre><br />
<br />
===Update===<br />
Once you check out a revision of odamex's source code, your local version of the code stays that way. If a newer version of the code comes out, you have two options. You can either check out a new version of the code into a seporate directory, or you can '''update''' the existing code that you already have. Note that any changes you have made to your local copy are kept, and not discarded, and if the version you download from the server collides with any of your changed files, subversion will tell you this, and you must handle the conflict between your local copy and the server's repository manually, usually through a revert, or by creating a new local copy so you don't lose your hard work..<br />
<br />
This is how you update from the command line:<br />
<br />
<pre>svn update <local directory></pre><br />
<br />
Note that you do not need to specify the server, as subversion remembers the server where your local copy originated from.<br />
<br />
To get a specific revision, use the "-r" parameter.<br />
<br />
==What Subversion clients are avalable?==<br />
There are many, many subversion clients avalable:<br />
* [http://subversion.tigris.org/ Subversion]: Command Line client for multiple platforms.<br />
* [http://tortoisesvn.tigris.org/ TortiseSVN]: Windows Explorer extension for Windows.<br />
* [http://rapidsvn.tigris.org/ RapidSVN]: wxWidgets based GUI client for multiple platforms.<br />
<br />
== How is Odamex's repository organized ==<br />
Each branch keeps an entire odamex source tree.<br />
<br />
* '''[http://www.odamex.net/svn root]'''<br />
** '''trunk''' - Bleeding-edge development, expect things to break often<br />
** '''branches'''<br />
*** '''ogl_hack''' - A very experimental attempt at creating an OpenGL-based renderer for Odamex<br />
*** other temporary branches may be created or destroyed<br />
** tags<br />
*** Each stable and development release is tagged. This is starting with 0.4 and will be back-tagged for prior releases.<br />
<br />
== How can I be notified when the repository updates? ==<br />
<br />
Any changes to our svn repository are reported in:<br />
* [http://odamex.net/changelog.php?count=100 The Odamex Changelog]<br />
* [[IRC|The Odamex IRC Channel]] by the odasvn bot.<br />
<br />
== Guidelines for maintainers ==<br />
<br />
* Do<br />
** Regularly update your working copy<br />
** Commit individual improvements and corrections to the existing code<br />
** Separate your commits semantically<br />
** Make an informative comment with each commit<br />
** Mention related bugs and revisions (see [http://odamex.net/changelog changelog] for examples)<br />
** Seek comments on bugzilla and forum before making major changes<br />
** Test your changes before every commit<br />
* Do not<br />
** Commit broken code to trunk or stable<br />
** Commit untested code to stable<br />
** Make giant monolithic commits<br />
** Make major changes without consulting maintainers<br />
** Make frivolous commits<br />
** Overwrite other people's recent work without asking them<br />
** Change EOL modes of files, All files should be LF</div>Voxelhttps://odamex.net/w/index.php?title=Subversion&diff=3247Subversion2008-07-18T20:31:18Z<p>Voxel: /* How can I be notified when the repository updates? */</p>
<hr />
<div>[[Image:Commits_group_multi_date_graph_2027.png|thumb|Graph of svn activity up to revision 2027, taken 14/11/06.]]<br />
<br />
== I don't feel like reading this whole document. How do I obtain and compile Odamex from Subversion? ==<br />
Following is the cheat-sheet command to build and run odamex from svn on a typical *nix system. This command is not guaranteed to work, in fact it is more likely to fail, you should not use it unless you understand what it does.<br />
<br />
<pre>cd; svn co http://odamex.net/svn/root/ odamex; cd odamex/trunk; make && ./odamex</pre><br />
<br />
== What is Subversion? ==<br />
<br />
Subversion is the current version control repository used to maintain the Odamex source code. In layman's terms, it allows multiple people to be working on the same project at the same time while giving those same people the facilities to recognize collisions between two contributors code.<br />
<br />
== How do I access Odamex's Subversion respository? ==<br />
<br />
Odamex's subversion repository can be accessed using the following URL:<br />
<br />
<pre>http://odamex.net/svn/root/</pre><br />
<br />
== What is Odamex's Subversion access policy? ==<br />
<br />
Read-only access to Odamex's Subversion repository is public, meaning that anyone can checkout the source for their own purposes, including modification and compilation. However, further repository access, such as Commit access, is restricted based on our [[Policy]]. If you wish to contribute to Odamex, please send a [[patch]] to one of the indicated [[MAINTAINERS]]. Those that contribute considerable time to improve the Odamex source may be granted full or partial access.<br />
<br />
Generally, the [[Policy|project manager(s)]] will administrate this access with the guidance of the lead coder(s). Inactive accounts will tend to get frozen or disabled after a certain length of time.<br />
<br />
== How do I use a subversion client? ==<br />
<br />
This depends on the subversion client you happen to be using. However, there are some terms that you should recognize that are consistant between clients.<br />
<br />
===Checkout===<br />
The process of '''checking out''' means that you connect to the subversion server and it downloads a revision of the code you specify and places it into a newly created subversion filesystem on your local hard drive. By default, the HEAD(latest) revision is the one that is checked out, and probably the one that you are most interested in.<br />
<br />
This is how you check out from the command line:<br />
<br />
<pre>svn checkout <server name> <destination directory></pre><br />
<br />
===Update===<br />
Once you check out a revision of odamex's source code, your local version of the code stays that way. If a newer version of the code comes out, you have two options. You can either check out a new version of the code into a seporate directory, or you can '''update''' the existing code that you already have. Note that any changes you have made to your local copy are kept, and not discarded, and if the version you download from the server collides with any of your changed files, subversion will tell you this, and you must handle the conflict between your local copy and the server's repository manually, usually through a revert, or by creating a new local copy so you don't lose your hard work..<br />
<br />
This is how you update from the command line:<br />
<br />
<pre>svn update <local directory></pre><br />
<br />
Note that you do not need to specify the server, as subversion remembers the server where your local copy originated from.<br />
<br />
To get a specific revision, use the "-r" parameter.<br />
<br />
==What Subversion clients are avalable?==<br />
There are many, many subversion clients avalable:<br />
* [http://subversion.tigris.org/ Subversion]: Command Line client for multiple platforms.<br />
* [http://tortoisesvn.tigris.org/ TortiseSVN]: Windows Explorer extension for Windows.<br />
* [http://rapidsvn.tigris.org/ RapidSVN]: wxWidgets based GUI client for multiple platforms.<br />
<br />
== How is Odamex's repository organized ==<br />
Each branch keeps an entire odamex source tree.<br />
<br />
* '''[http://www.odamex.net/svn root]'''<br />
** '''trunk''' - Bleeding-edge development, expect things to break often<br />
** '''branches'''<br />
*** '''ogl_hack''' - A very experimental attempt at creating an OpenGL-based renderer for Odamex<br />
*** other temporary branches may be created or destroyed<br />
** tags<br />
*** Each stable and development release is tagged. This is starting with 0.4 and will be back-tagged for prior releases.<br />
<br />
== How can I be notified when the repository updates? ==<br />
<br />
Any changes to our svn repository are reported in:<br />
* [http://odamex.net/changelog?count=100 The Odamex Changelog]<br />
* [[IRC|The Odamex IRC Channel]] by the odasvn bot.<br />
<br />
== Guidelines for maintainers ==<br />
<br />
* Do<br />
** Regularly update your working copy<br />
** Commit individual improvements and corrections to the existing code<br />
** Separate your commits semantically<br />
** Make an informative comment with each commit<br />
** Mention related bugs and revisions (see [http://odamex.net/changelog changelog] for examples)<br />
** Seek comments on bugzilla and forum before making major changes<br />
** Test your changes before every commit<br />
* Do not<br />
** Commit broken code to trunk or stable<br />
** Commit untested code to stable<br />
** Make giant monolithic commits<br />
** Make major changes without consulting maintainers<br />
** Make frivolous commits<br />
** Overwrite other people's recent work without asking them<br />
** Change EOL modes of files, All files should be LF</div>Voxelhttps://odamex.net/w/index.php?title=Coding_standard&diff=3206Coding standard2008-06-03T19:28:45Z<p>Voxel: </p>
<hr />
<div>==Overview==<br />
Odamex relies on a coding standard to ensure continuity, this reduces bugs and provides easy readability of the code.<br />
<br />
==Requirements==<br />
<br />
* Make logical changes in separate patches<br />
* Minimise the number of changes in each patch<br />
* Provide an off switch for every new feature<br />
* Do not submit things you cannot test (e.g. code for alternative platforms)<br />
<br />
==Code guidelines==<br />
=== General ===<br />
* Add a [[test]] for every change (or an explanation of why this is impossible)<br />
<br />
Things you should definitely AVOID in your code:<br />
* Changing code that already works<br />
* Precompiler macros<br />
* Global variables (they can create problems elsewhere in code)<br />
* Variants (tagged unions) - they can present a performance problem<br />
* Magic numbers (use #define or const in your code for fixed numbers, at the top of files)<br />
* Hungarian notation (just plan evil)<br />
* C style strings. (replace them with C++ types where it is safe to do so)<br />
* goto<br />
<br />
=== Memory Management ===<br />
If you need to use malloc(), calloc(), realloc(), free() functions. Use the '''macros''' located in '''m_alloc.h''', these are provided because they are much better when it comes to debugging code and such:<br />
<br />
* M_Malloc(size_t Size)<br />
* M_Calloc(size_t Items, size_t Size)<br />
* M_Realloc(void *Pointer, size_t Size)<br />
* M_Free(uintptr_t &Reference)<br />
<br />
A list of features these functions offer:<br />
<br />
* The Size value can NEVER be 0, this prevents platform-specific behaviour.<br />
* M_Free uses a reference instead of a pointer, it still does the same as normal free(), but will NULL the address on return.<br />
* They will abort the program if their operation fails.<br />
<br />
=== Z_Zone Memory Management ===<br />
* Be aware that the all Z_Zone allocated memory is freed when the WAD changes<br />
<br />
=== Formatting ===<br />
<br />
* If creating a new file, include a GPL header at the top of it, as seen in other files.<br />
* Descriptive comments<br />
* Comments of reasonable size. (not too big and not too small)<br />
* Comment formatting. (in c/c++, either // for 1 liners or /* */ for multiple lines)<br />
* Indentations to be of 1 tab character, using 4 space width tabs<br />
* Be sure your editor/IDE's EOL mode is LF, not CRLF or CR<br />
* 80 line character limit, for devs with text-based editors<br />
* if you can, limit functions to a maximum size (like the amount that would fit on a monitor with a reasonable screen resolution)<br />
<br />
What you should strive for:<br />
* Clarity of code<br />
* Defensive and secure coding practices<br />
* Maintain traditional naming conventions, for consistency<br />
<br />
==External Links==<br />
<br />
* [http://www.jwz.org/doc/tabs-vs-spaces.html tabs-vs-spaces]</div>Voxelhttps://odamex.net/w/index.php?title=Test&diff=3192Test2008-06-03T00:12:28Z<p>Voxel: /* See also */</p>
<hr />
<div>Odamex has a lot of working features. The doom engine is sensitive to change, so to preserve functionality we have a set of tests to run on every submission. They are located in the tests directory.<br />
<br />
==Running tests==<br />
You will need to have [http://tcl.tk/ TCL] installed (free download available from [http://www.activestate.com/store/activetcl/download/ ActiveState])<br />
<br />
===Under Windows===<br />
<br />
You must build odamex as a console application. This is because if you run odamex from the command window (Start, Run: cmd) and it detaches from the command console, the tests will not work.<br />
<br />
Open a command window (Start, Run: cmd). Navigate to your binary directory (the one which contains client and server binaries). Run one of the tests:<br />
<pre><br />
cd trunk\bin<br />
tclsh85 ..\tests\commands\cmdSay.tcl<br />
</pre><br />
<br />
===Under Unix===<br />
You can run all tests with ''make test'', or a specific test by navigating to the working directory and invoking one of the tcl test scripts from there:<br />
<pre><br />
cd trunk<br />
tests/commands/cmdSay.tcl<br />
</pre><br />
<br />
==Writing tests==<br />
Tests are written in [http://tcl.tk TCL] (pronounced ''tickle''), as this is a portable easy to learn scripting language. It is best to start by copying an existing test. Tests should output lines containing the words "PASS" or "FAIL".<br />
<br />
Tests can start/stop clients and servers, send them commands and monitor the output. Complexity of the test increases with the complexity of the feature, this encourages smaller changes.<br />
<br />
==Example==<br />
<br />
<pre><br />
#!/bin/bash<br />
# Do not change these first three lines \<br />
exec tclsh "$0" "$@"<br />
<br />
# Create a list of demos to test (a list of lists of 3 items)<br />
lappend demos "DOOM2.WAD DEMO1 {15eb4720 3ccc7a1 3fc7e27 800000}"<br />
lappend demos "DOOM2.WAD DEMO2 {cea29400 289b9c2 fece4356 600000}"<br />
lappend demos "DOOM2.WAD DEMO3 {dca00040 fd6a4b9c ff7bee0a ff000000}"<br />
<br />
foreach demo $demos {<br />
# Run this demo<br />
set stdout [exec ./odamex -nosound -novideo \<br />
-iwad [lindex $demo 0] \<br />
+demotest [lindex $demo 1]]<br />
<br />
# Take the last line of output<br />
set result [lindex [split $stdout "\n"] end]<br />
<br />
# Take the last item in this demo line (see top of test)<br />
set expected [lindex $demo 2]<br />
<br />
# Compare them<br />
if { $result != $expected} {<br />
puts "FAIL $demo | $result"<br />
} else {<br />
puts "PASS $demo | $result"<br />
}<br />
}<br />
</pre><br />
<br />
==Advanced TCL==<br />
All relevant documentation is easily available on the internet; this section briefly talks about things you are likely to encounter<br />
<br />
===Pipes===<br />
''exec'' is a synchronous command, it will wait for execution to finish before returning control to your script. This is not good when you want to control both a client and a server. What you need is a pipe:<br />
<br />
<pre><br />
set control [open "|./odamex" "w"]<br />
</pre><br />
<br />
Problem is, pipes are one-way (either read only or write only), so you'd need to redirect the output and read it a different manner (after a short delay to allow the output file to be created):<br />
<br />
<pre><br />
set control [open "|./odamex > odamex.log" "w"]<br />
exec sleep 1<br />
set output [open "odamex.log" "r"]<br />
</pre><br />
<br />
And you must remember to close both pipes, but before you do, you must ensure that the application has quit (otherwise ''close'' will never complete). To do this, use ''puts'' to write the quit command to the client (as if it were typed). Applications do not like multiple puts without having the stream flushed, so a ''flush'' follows the ''puts''.<br />
<br />
<pre><br />
set control [open "|./odamex > odamex.log" w]<br />
exec sleep 1<br />
set output [open "odamex.log" r]<br />
<br />
puts $control quit<br />
flush $control<br />
<br />
close $control<br />
close $output<br />
</pre><br />
<br />
Most of this functionality should be put into separate procs so that it does not hurt your head. A lot of it is already available as functions within existing tests, which you can copy.<br />
<br />
==See also==<br />
* [[Coding standard]]<br />
* [http://odamex.org/regression.html Latest regression test report]</div>Voxelhttps://odamex.net/w/index.php?title=Console&diff=3190Console2008-06-02T19:02:09Z<p>Voxel: </p>
<hr />
<div>Odamex supports a quake-style console system. You can access it by using the tilde (~) or grave (&not;) key, depending on your keyboard layout.<br />
<br />
If this does not work, use the 'Escape' key to open the menu, then by using the arrow keys and Enter: select "Options", then "Customize controls", then "Console". Hit a key you wish to use to access the console.</div>Voxelhttps://odamex.net/w/index.php?title=Console&diff=3189Console2008-06-02T19:01:53Z<p>Voxel: </p>
<hr />
<div>Odamex supports a quake-style console system. You can access it by using the tilde (~) or grave key (&not;), depending on your keyboard layout.<br />
<br />
If this does not work, use the 'Escape' key to open the menu, then by using the arrow keys and Enter: select "Options", then "Customize controls", then "Console". Hit a key you wish to use to access the console.</div>Voxelhttps://odamex.net/w/index.php?title=Console&diff=3188Console2008-06-02T18:59:01Z<p>Voxel: </p>
<hr />
<div>Odamex supports a quake-style console system. You can access it by using the tilde or grave key (~ or �), depending on your keyboard layout.<br />
<br />
If this does not work, use the 'Escape' key to open the menu, then by using the arrow keys and Enter: select "Options", then "Customize controls", then "Console". Hit a key you wish to use to access the console.</div>Voxelhttps://odamex.net/w/index.php?title=Commands&diff=3187Commands2008-06-02T18:56:04Z<p>Voxel: </p>
<hr />
<div>Commands can be used to control odamex or to retrieve information. Startup commands can be given to both [[Server|server]] and [[Client|client]] as parameters prefixed with '+' on the [http://en.wikipedia.org/wiki/Command_line command line]. You can enter commands at the server terminal or at the client [[console]].<br />
<br />
There are:<br />
* [[:Category:Client commands|Client commands]]<br />
* [[:Category:Server commands|Server commands]]<br />
<br />
The startup parameters are:<br />
<br />
* [[:Category:Client parameters|Client parameters]]<br />
* [[:Category:Server parameters|Server parameters]]</div>Voxelhttps://odamex.net/w/index.php?title=Novideo&diff=3186Novideo2008-06-02T18:54:57Z<p>Voxel: </p>
<hr />
<div>odamex -novideo<br />
<br />
does not initialise the window system, good for testing and troubleshooting<br />
<br />
== See also ==<br />
* [[nosound]]<br />
<br />
[[Category:Client_parameters]]</div>Voxelhttps://odamex.net/w/index.php?title=Nosound&diff=3185Nosound2008-06-02T18:54:20Z<p>Voxel: </p>
<hr />
<div>odamex -nosound<br />
<br />
does not initialise the sound system, good for testing and troubleshooting<br />
<br />
== See also ==<br />
* [[novideo]]<br />
<br />
[[Category:Client_parameters]]</div>Voxelhttps://odamex.net/w/index.php?title=Logfile&diff=3184Logfile2008-06-02T18:48:10Z<p>Voxel: </p>
<hr />
<div>-logfile <filename><br />
<br />
the parameter specifies the filename to which the [[client]] or [[server]] copies its output to<br />
<br />
for example:<br />
<br />
odamex -logfile odamex.log<br />
<br />
[[Category:Client_parameters]]<br />
[[Category:Server_parameters]]</div>Voxelhttps://odamex.net/w/index.php?title=Logfile&diff=3183Logfile2008-06-02T18:45:52Z<p>Voxel: </p>
<hr />
<div>-logfile <filename><br />
<br />
the parameter specifies the filename to which the [[client]] or [[server]] copies its output to<br />
<br />
for example:<br />
<br />
odamex -logfile odamex.log</div>Voxelhttps://odamex.net/w/index.php?title=Playdemo&diff=3181Playdemo2008-06-01T12:08:18Z<p>Voxel: </p>
<hr />
<div>===playdemo===<br />
After starting odamex or running odamex with +playdemo, this command plays a recorded demo<br />
<br />
''Ex. If you wanted to play a vanilla demo, you would type '''playdemo demotitle.lmp'''. If the demo is located in a different directory other than odamex, you would type '''playdemo C:\path\to\demo\demotitle.lmp''' or in *nix '''playdemo /home/<user>/path/to/demo/demotitle.lmp'''<br />
<br />
==See also==<br />
* [[recordvanilla]]<br />
<br />
[[Category:Client_commands]]</div>Voxelhttps://odamex.net/w/index.php?title=Recordvanilla&diff=3180Recordvanilla2008-06-01T12:07:57Z<p>Voxel: </p>
<hr />
<div>==recordvanilla==<br />
In odamex, this will record a vanilla doom demo.<br />
<br />
''Ex. If you wanted to record a demo of a map01 run, you would use '''recordvanilla map01 demotitle'''<br />
<br />
You can also run odamex with "+recordvanilla map demoname" on the commandline<br />
<br />
==recordlongticks==<br />
This is like recordvanilla, only it records demos in the longticks format. Consult the Doom Wiki.<br />
<br />
==See also==<br />
* [[playdemo]]<br />
<br />
[[Category:Client_commands]]</div>Voxelhttps://odamex.net/w/index.php?title=Recordvanilla&diff=3179Recordvanilla2008-06-01T12:04:26Z<p>Voxel: </p>
<hr />
<div>==recordvanilla==<br />
In odamex, this will record a vanilla doom demo.<br />
<br />
''Ex. If you wanted to record a demo of a map01 run, you would use '''recordvanilla map01 demotitle'''<br />
<br />
You can also run odamex with "+recordvanilla map demoname" on the commandline<br />
<br />
==recordlongticks==<br />
This is like recordvanilla, only it records demos in the longticks format. Consult the Doom Wiki.<br />
<br />
[[Category:Client_commands]]</div>Voxelhttps://odamex.net/w/index.php?title=Recordvanilla&diff=3178Recordvanilla2008-06-01T12:03:57Z<p>Voxel: </p>
<hr />
<div>==recordvanilla==<br />
In odamex, this will record a vanilla doom demo.<br />
<br />
''Ex. If you wanted to record a demo of a map01 run, you would use '''recordvanilla map01 demotitle'''<br />
<br />
You can also run odamex with +recordvanilla<br />
<br />
==recordlongticks==<br />
This is like recordvanilla, only it records demos in the longticks format. Consult the Doom Wiki.<br />
<br />
[[Category:Client_commands]]</div>Voxelhttps://odamex.net/w/index.php?title=Recordvanilla&diff=3177Recordvanilla2008-06-01T12:03:18Z<p>Voxel: </p>
<hr />
<div>==recordvanilla==<br />
After starting odamex or running odamex with +recordvanilla, this will record a vanilla doom demo.<br />
<br />
''Ex. If you wanted to record a demo of a map01 run, you would use '''recordvanilla map01 demotitle'''<br />
<br />
==recordlongticks==<br />
This is like recordvanilla, only it records demos in the longticks format. Consult the Doom Wiki.<br />
<br />
[[Category:Client_commands]]</div>Voxelhttps://odamex.net/w/index.php?title=Frequently_Asked_Questions&diff=3176Frequently Asked Questions2008-06-01T12:02:13Z<p>Voxel: /* How do I record and/or playback Demo files? */</p>
<hr />
<div>Do you have a question you feel is worthy of the FAQ? Send a private message to [http://odamex.net/boards/index.php?action=pm;sa=send;u=1 Manc] with your question (and answer if you have it).<br />
<br />
== General Questions ==<br />
=== Why Odamex? ===<br />
Odamex follows the philosophy of the free software movement. We feel that as a community we can make our software better. Since we feel so strongly about this belief we have chosen to release the Odamex source code under the GNU GPLv2 [[license]].<br />
<br />
=== Will Odamex support advanced features? ===<br />
That depends entirely on what you consider advanced features. Odamex strives for full Boom compatibility and also has other enhancements over regular Doom such as mouselook and jumping (which can both be turned off on the server level). Due to license conflicts, all Hexen source had to be removed or replaced.<br />
<br />
== Requirements ==<br />
===What platforms can Odamex run on?===<br />
Odamex has been tested and has been confirmed to compile and run on the following operating systems and chipsets:<br />
<br />
====Intel x86====<br />
* Windows NT family (Vista, XP, 2000, 2003)<br />
* Windows 9x family (98, 95, Me)<br />
* Linux<br />
* FreeBSD<br />
* OpenBSD<br />
* Solaris<br />
* Mac OS X<br />
<br />
====PowerPC====<br />
* Mac OS X<br />
* Linux<br />
<br />
====SPARC====<br />
* Solaris<br />
<br />
If your operating system and chipset combination is not listed above, however, this does not necessarily mean that Odamex will not run on it. Odamex was designed with portability in mind, and it may very well run on your favorite system and we may not even know it. If you can get Odamex to compile and run on an operating system/chipset combination not listed here, please [[Credits | let us know]].<br />
<br />
=== Are there any set hardware requirements? ===<br />
Not really. Given the software requirements being fulfilled, Odamex has run on pretty much everything we've thrown at it. If you can find a hardware combination that fulfills the software requirements but that Odamex will not run on, let us know.<br />
<br />
=== What data files are required? ===<br />
Odamex requires a resource file from Doom or Doom 2 in order to play online. The most common resource files needed to play are:<br />
<br />
{|border=1<br />
<br />
|-<br />
! Resource !!Title !!Version !!Availability<br />
<br />
|-<br />
|DOOM1.WAD<br />
|[http://www.idsoftware.com Doom 1: Knee-Deep in the Dead]<br />
|v1.9<br />
|style="color:orange"|<br />
shareware<br />
<br />
|-<br />
|DOOM.WAD<br />
|[http://www.idsoftware.com Ultimate Doom]<br />
|v1.9<br />
|style="color:red"|<br />
commercial<br />
<br />
|-<br />
|DOOM2.WAD<br />
|[http://www.idsoftware.com Doom II]<br />
|v1.9<br />
|style="color:red"|<br />
commercial<br />
<br />
|-<br />
|TNT.WAD<br />
|[http://www.idsoftware.com Final Doom: TNT Evilution]<br />
|v1.9<br />
|style="color:red"|<br />
commercial<br />
<br />
|-<br />
|PLUTONIA.WAD<br />
|[http://www.idsoftware.com Final Doom: The Plutonia Experiment]<br />
|v1.9<br />
|style="color:red"|<br />
commercial<br />
<br />
|-<br />
|FREEDOOM.WAD<br />
|[http://freedoom.sourceforge.net FreeDoom]<br />
|v0.6.2<br />
|style="color:green"|<br />
free<br />
<br />
|}<br />
<br />
The version number is important. There are several versions of most of these resource files floating around, and resources from one version may not work with another, so for consistencies sake the latest version is assumed. If you have a copy of Doom Collectors Edition or a version of Ultimate Doom or Doom 2 that is for Windows 95, then you are using the latest version of those resource files. If you have a copy of Doom or Doom 2 for DOS, please patch your resource file to the latest version. <br />
<br />
The following are free to download and use:<br />
<br />
* [http://freedoom.sourceforge.net FreeDoom] - "The Freedoom project aims to create a complete Doom-based game which is Free Software."<br />
* [ftp://ftp.idsoftware.com/idstuff/doom/doom19s.zip Doom Shareware] - "The wad that started it all!" (v1.9)<br />
<br />
== Playability ==<br />
=== What's up with this? I can't connect to some of the servers! ===<br />
Updates to the codebase are frequent. There are some servers which are running out-of-date versions of Odamex, some that are running the latest public release of Odamex, and some that are running SVN versions of Odamex. We suggest that all servers and clients run the latest public (non-SVN) release of Odamex unless they are specificly marked as development servers. If you see someone running an older version, please contact the server administrator.<br />
<br />
=== Movement seems to be jerky. Watching people move from one place to another is like watching a slideshow! ===<br />
Pardon our mess. =) As Odamex is still in development, we are still working on the netcode, and trying to find the best combination of smooth gameplay, reliability and exploit prevention. However, as you can probably tell, it's not quite there yet. Rest assured, as Odamex's development continues, the quality of the netcode will continue to improve until it is considered acceptable.<br />
<br />
=== There seems to be some weird behavior in general. Odamex acts funny/disconnects me unexpectedly/crashes/other bad things. ===<br />
Bugs, unfortunately, are a real and present part of software development. Odamex is no exception. The good news, however, is that you - yes you - regardless of software development or prior experience, can help us track down and fix these bugs. Please read the section on [[Bugs]] for more information on how you can help.<br />
<br />
=== Help! Everyone moves too fast and I get killed within seconds! ===<br />
Please read the article about [[gameplay]] for a short introduction to Doom's very unique style of Deathmatch.<br />
<br />
=== I am a veteran doom2.exe player. What does Odamex offer me? ===<br />
With the default server configuration, Odamex offers a client/server multiplayer environment that closely emulates the standard gameplay mechanics created by id Software back in 1993 with the initial release of Doom. <br />
<br />
=== I love enhanced gameplay and features. What does Odamex offer me? ===<br />
Players who prefer an enhanced experience to Doom can play in teamplay modes, such as Team Deathmatch and Capture the Flag. They also have the option to jump and to use freelook to guide their vertical aiming on servers which allow it (see [[allowfreelook]] and [[allowjump]]).<br />
<br />
=== How do I record and/or playback Demo files? ===<br />
See the [[recordvanilla]] console command<br />
<br />
== Security ==<br />
=== What is being done about the security of Odamex? ===<br />
* Multiple master support has been added to protect our network<br />
* All important communication paths have challenge/response spoof protection<br />
* [[rcon_password]] uses MD5 digest so that passwords are not sent in plain text<br />
=== How will cheaters be dealt with? ===<br />
See the [[Cheating|cheating]] page.<br />
<br />
== Development ==<br />
=== When will Odamex be released? ===<br />
There is currently no definitive date for a release. However, you can catch up on Odamex progress by reading the [[development roadmap]] and viewing the [http://odamex.net/changelog changelog].<br />
<br />
=== I want to contribute to Odamex! What can I do to help? ===<br />
There are many things you can do to contribute to Odamex. You could help by reporting [[bugs]] or by spreading the word around to your friends. If you are a programmer you can submit [[patches]] to the development team for possible inclusion in the next revision.<br />
<br />
=== I found a bug! What should I do? ===<br />
See [[Bugs]] for more information.<br />
<br />
== Misc ==<br />
=== What does the name 'Odamex' mean? ===<br />
The word Odamex is not necessarily an acronym. It is not represented as such anywhere in the application or this website. However, it was originally thought of as such, so included below are some ideas of what it could be:<br />
<br />
* What fraggle says when he is trying to get X working in Linux. "<fraggle> oh, damn X!"<br />
* "Oh! Yes! Fur!" as read in Russian<br />
* Online Doom Multiplayer EXperience</div>Voxelhttps://odamex.net/w/index.php?title=Debian_package&diff=3170Debian package2008-05-29T12:21:32Z<p>Voxel: </p>
<hr />
<div>This is how to build the Debian/Ubuntu package<br />
<br />
= Instructions =<br />
<br />
* Install all of the debian packaging utilities and the build environment utilities. Also make sure you have libsdl-dev,libsdl-mixer1.2-dev and wxgtk installed- sudo apt-get install dpkg-dev file gcc g++ libc6-dev <br />
<br />
* make patch perl autoconf automake dh-make debhelper devscripts gnupg <br />
<br />
* Download the skeleton debian packaging at http://nuxified.org/odamex/odamex-0.<version>/skel.tar.gz<br />
<br />
* Create a folder titled 'odamex-<version>'. Example: mkdir odamex-0.3<br />
<br />
* Grab a source tarball from http://odamex.net/ and place it in the same place as the directory 'odamex-<version>'<br />
<br />
* cd into the directory 'odamex-<version>'<br />
<br />
* run dh_make -e your.email@address -f ../<name of the tarball you downloaded><br />
<br />
* remove the newly created debian/ and extract the skeleton into the directory<br />
<br />
* if the source code is not already in the directory with debian/, extract the tarball you downloaded inside the directory.<br />
<br />
* run 'dpkg-buildpackage -rfakeroot' in the same directory with debian/<br />
<br />
* you should have a .deb package up one directory if everything checked out right<br />
<br />
* to rebuild without recompiling, run 'fakeroot debian/rules binary'</div>Voxelhttps://odamex.net/w/index.php?title=Debian_package&diff=3169Debian package2008-05-29T12:20:38Z<p>Voxel: </p>
<hr />
<div>This is how to build the Debian/Ubuntu package<br />
<br />
= Instructions =<br />
<br />
Install all of the debian packaging utilities and the build environment utilities. Also make sure you have libsdl-dev,libsdl-mixer1.2-dev and wxgtk installed- sudo apt-get install dpkg-dev file gcc g++ libc6-dev <br />
<br />
make patch perl autoconf automake dh-make debhelper devscripts gnupg <br />
<br />
Download the skeleton debian packaging at http://nuxified.org/odamex/odamex-0.<version>/skel.tar.gz<br />
<br />
Create a folder titled 'odamex-<version>'. Example: mkdir odamex-0.3<br />
<br />
Grab a source tarball from http://odamex.net/ and place it in the same place as the directory 'odamex-<version>'<br />
<br />
cd into the directory 'odamex-<version>'<br />
<br />
run dh_make -e your.email@address -f ../<name of the tarball you downloaded><br />
<br />
remove the newly created debian/ and extract the skeleton into the directory<br />
<br />
if the source code is not already in the directory with debian/, extract the tarball you downloaded inside the directory.<br />
<br />
run 'dpkg-buildpackage -rfakeroot' in the same directory with debian/<br />
<br />
you should have a .deb package up one directory if everything checked out right<br />
<br />
step 11: to rebuild without recompiling, run 'fakeroot debian/rules binary'</div>Voxelhttps://odamex.net/w/index.php?title=Debian_package&diff=3168Debian package2008-05-29T12:19:59Z<p>Voxel: </p>
<hr />
<div>Install all of the debian packaging utilities and the build environment utilities. Also make sure you have libsdl-dev,libsdl-mixer1.2-dev and wxgtk installed- sudo apt-get install dpkg-dev file gcc g++ libc6-dev <br />
This is how to build the Debian/Ubuntu package<br />
<br />
= Instructions =<br />
<br />
make patch perl autoconf automake dh-make debhelper devscripts gnupg <br />
<br />
Download the skeleton debian packaging at http://nuxified.org/odamex/odamex-0.<version>/skel.tar.gz<br />
<br />
Create a folder titled 'odamex-<version>'. Example: mkdir odamex-0.3<br />
<br />
Grab a source tarball from http://odamex.net/ and place it in the same place as the directory 'odamex-<version>'<br />
<br />
cd into the directory 'odamex-<version>'<br />
<br />
run dh_make -e your.email@address -f ../<name of the tarball you downloaded><br />
<br />
remove the newly created debian/ and extract the skeleton into the directory<br />
<br />
if the source code is not already in the directory with debian/, extract the tarball you downloaded inside the directory.<br />
<br />
run 'dpkg-buildpackage -rfakeroot' in the same directory with debian/<br />
<br />
you should have a .deb package up one directory if everything checked out right<br />
<br />
step 11: to rebuild without recompiling, run 'fakeroot debian/rules binary'</div>Voxelhttps://odamex.net/w/index.php?title=How_to_build_from_source&diff=3167How to build from source2008-05-29T12:18:24Z<p>Voxel: </p>
<hr />
<div>Odamex is open source. This means that it is possible to obtain and compile Odamex from source if you so desire. The Odamex team wishes to make this process as painless as possible, therefore detailed instructions for how to build Odamex are provided in this section.<br />
<br />
=Getting the source=<br />
There are two ways to obtain the source to Odamex:<br />
<br />
* [http://odamex.net/ Download] the latest stable version from the official Odamex website<br />
* Get the absolute latest modifications through anonymous [[Subversion]] access<br />
<br />
=Getting required files=<br />
When you download Odamex, it's almost ready to go, right out of the box. However, you need something to compile it with. In addition, Odamex relies on extra libraries in order to function.<br />
<br />
* [[Required Libraries]]<br />
<br />
=Compiling Odamex=<br />
You have all the pieces of the puzzle...now it's time to build.<br />
<br />
Depending on what operating system and hardware you are running, you have many options of compilers. Some of the more popular choices are below:<br />
<br />
==Windows==<br />
===Code::Blocks IDE and MinGW===<br />
This is the prefered method of compiling Odamex on Windows. Code::Blocks project and workspace files are included in the [[Subversion]].<br />
* See [[Compiling using Code::Blocks]]<br />
<br />
===MinGW and MSYS===<br />
This method of compiling utilizes the command line to compile Odamex. This is useful if you prefer not to use an IDE.<br />
* See [[Compiling using MSYS]]<br />
<br />
===Microsoft Visual Studio===<br />
Odamex currently supports compiling under Microsoft Visual C++ 6.0, and a Visual C++ 6.0 project file is included in [[Subversion]]. Support for later versions of Visual Studio is unconfirmed.<br />
* See [[Compiling using Microsoft Visual Studio]]<br />
<br />
===Cygwin and GCC===<br />
Support for native Cygwin binaries is not supported at this time, though is both feasable and desirable in the future. You can, however, compile Odamex without Cygwin support under Cygwin, with minor adjustments, though this is not considered "Cygwin GCC".<br />
* See [[Compiling using GCC]]<br />
<br />
=== Installer ===<br />
* See [[NSIS]]<br />
<br />
==Linux==<br />
===GCC===<br />
This is the prefered method of compiling Odamex in Linux. Makefiles are included in the [[Subversion]].<br />
* See [[Compiling using GCC]]<br />
<br />
=== Debian/Ubuntu Package ===<br />
* See [[Debian package]]<br />
<br />
==FreeBSD==<br />
===GCC===<br />
This is the prefered method of compiling Odamex in FreeBSD. Makefiles are included in [[Subversion]], and should work with the FreeBSD version of GNU Make (gmake) and GCC.<br />
* See [[Compiling using GCC]]<br />
<br />
==OSX==<br />
===Xcode===<br />
* See [[Compiling using Xcode]]<br />
<br />
=Cross compiling=<br />
You can build the windows version of odamex on linux:<br />
* See [[Cross compiling for Windows using MinGW]]<br />
<br />
=Compiling the Launcher=<br />
So you want to mess around with the Launcher? Here's how to do it.<br />
<br />
* See [[Compiling the Launcher using Code::Blocks]]<br />
* See [[Compiling the Launcher using GCC]]<br />
<br />
=Building odamex.wad=<br />
This will show you how to build the latest odamex.wad file<br />
<br />
* [[Building odamex.wad using DeuTex]] on multiple platforms<br />
<br />
''Note: odamex.wad gets built automatically when using the Makefile</div>Voxelhttps://odamex.net/w/index.php?title=Next_release&diff=3149Next release2008-05-24T18:25:35Z<p>Voxel: /* Explanation */</p>
<hr />
<div>= When will the next version come out? =<br />
When you build it.<br />
<br />
== Explanation ==<br />
Odamex is built by volunteers. The more work you do, the quicker stuff is released. If you don't know what to do, just ask. We always have things that need doing. No experience required, just effort.<br />
<br />
* You have access to all the tools that our development team has.<br />
* You have access to all the current resources.<br />
* You have access to all the current code.<br />
* You have access to the same bug tracker, wiki and forum as we do.<br />
* You are our development team!<br />
<br />
== About version hype ==<br />
Version numbers are just that, numbers. They don't mean anything, except that some changes have been made. The changes may be structural and unrelated to the gaming experience, or for some obscure operating system that you'll never have. Heck, we can take the current code and call it the "next version". It is stupid to look forward to a version release unless you know what changes will be made and want those specific changes.</div>Voxelhttps://odamex.net/w/index.php?title=Releases&diff=3147Releases2008-05-24T02:27:29Z<p>Voxel: /* Changes since 0.2a */</p>
<hr />
<div>= Odamex 0.3 (r476) =<br />
Odamex 0.3 is the first version to remove the alpha status.<br />
<br />
== Changes ==<br />
A myriad of changes have been added since the previous version, such as:<br />
* Removal of non-free resources<br />
* Cvar and code additions, removals and cleanups<br />
* Single player mode readded<br />
* More bug fixes<br />
* Demo compatibility fixes<br />
* Launcher improvements<br />
<br />
A comprehensive list of changes can be found in the CHANGELOG file<br />
shipped with Odamex.<br />
<br />
== Downloads ==<br />
* [https://sourceforge.net/project/showfiles.php?group_id=144102&package_id=158375&release_id=551707 File List for 0.3]<br />
* [http://downloads.sourceforge.net/odamex/odamex-0.3-osx.zip?modtime=1194368610&big_mirror=0 Mac OS X Binaries]<br />
* [http://downloads.sourceforge.net/odamex/Odamex-0.3-win32.zip?modtime=1194135365&big_mirror=0 Windows Binaries]<br />
* [http://downloads.sourceforge.net/odamex/Odamex-0.3-src.tar.bz2?modtime=1194169236&big_mirror=0 Source Code]<br />
<br />
= Odamex 0.2a (r149) =<br />
<br />
= Odamex 0.1a (r33) =</div>Voxelhttps://odamex.net/w/index.php?title=Releases&diff=3146Releases2008-05-24T02:26:25Z<p>Voxel: /* Changes since 0.2a (r149) */</p>
<hr />
<div>= Odamex 0.3 (r476) =<br />
Odamex 0.3 is the first version to remove the alpha status.<br />
<br />
== Changes since 0.2a ==<br />
A myriad of changes have been added since the previous version, such as:<br />
* Removal of non-free resources<br />
* Cvar and code additions, removals and cleanups<br />
* Single player mode readded<br />
* More bug fixes<br />
* Demo compatibility fixes<br />
* Launcher improvements<br />
<br />
A comprehensive list of changes can be found in the CHANGELOG file<br />
shipped with Odamex.<br />
<br />
== Downloads ==<br />
* [https://sourceforge.net/project/showfiles.php?group_id=144102&package_id=158375&release_id=551707 File List for 0.3]<br />
* [http://downloads.sourceforge.net/odamex/odamex-0.3-osx.zip?modtime=1194368610&big_mirror=0 Mac OS X Binaries]<br />
* [http://downloads.sourceforge.net/odamex/Odamex-0.3-win32.zip?modtime=1194135365&big_mirror=0 Windows Binaries]<br />
* [http://downloads.sourceforge.net/odamex/Odamex-0.3-src.tar.bz2?modtime=1194169236&big_mirror=0 Source Code]<br />
<br />
= Odamex 0.2a (r149) =<br />
<br />
= Odamex 0.1a (r33) =</div>Voxelhttps://odamex.net/w/index.php?title=Timeline&diff=3145Timeline2008-05-24T02:26:03Z<p>Voxel: /* 2007 */</p>
<hr />
<div>This is a Timeline of events and milestones of the Odamex project, from the founding of Zwango until the present state of the project.<br />
<br />
===2005===<br />
* Odamex's precursor, Zwango, was created and the first binary build was dated July 2nd. The lead programmer was anarkavre and the project leader was Ralphis. The first launcher was developed by Russell, the earliest known build is dated July 5th.<br />
* On August 25th, Zwango was renamed to Odamex by the team.<br />
* Toke programmed CTF into Odamex, first CTF alpha dated September 8th.<br />
* New lead programmer, denis, joins the project on September 23rd.<br />
* SVN Repository created on October 1st.<br />
<br />
===2006===<br />
* Odamex gains initial support of SDL on January 10th, and completely replaces old ZDoom dependencies by January 13th.<br />
* Java launcher is created by AlexMax on January 24th, the first attempt to create a cross-platform launcher.<br />
* Milestone: 500th SVN commit on January 29th.<br />
* Milestone: 1000th SVN commit on February 28th.<br />
* The goal to make Odamex GPL compatible first made progress on March 11th.<br />
* Odamex team member Toke passes away on August 19th.<br />
* Self-zero pointer code introduced on September 26th which significantly reduced crashes and automatically resets servers.<br />
* Manc officially opened the website on October 23rd.<br />
* Milestone: 2000th SVN commit on November 11th.<br />
<br />
===2007===<br />
* On January 14th, the Odamex source was [[http://odamex.net/boards/index.php?topic=69 officially declared GPL compliant.]]<br />
* On January 15th, The private SVN ended with 2125 revisions and the public SVN was turned on.<br />
* On January 19th, the first public binaries of Odamex are posted as "Alpha version 0.1".<br />
* On February 20th, the second public binaries of Odamex are posted as "Alpha version 0.2".<br />
* On November 4th, Odamex "[[Releases|0.3]]" is officially released. The alpha/beta prefix is dumped.<br />
* On November 5th, the results of the first Odamex contest are revealed. The contest was to make a 1-on-1 map for use at Odamex's visit to MAGFest.<br />
<br />
===2008===<br />
* Odamex visits [[http://magfest.org Magfest]] from January 3rd through January 6th. The visit is a viewed as a [[http://youtube.com/watch?v=eM8f1GYYCf8 success]].</div>Voxelhttps://odamex.net/w/index.php?title=Releases&diff=3144Releases2008-05-24T02:25:51Z<p>Voxel: </p>
<hr />
<div>= Odamex 0.3 (r476) =<br />
Odamex 0.3 is the first version to remove the alpha status.<br />
<br />
== Changes since 0.2a (r149) ==<br />
A myriad of changes have been added since the previous version, such as:<br />
* Removal of non-free resources<br />
* Cvar and code additions, removals and cleanups<br />
* Single player mode readded<br />
* More bug fixes<br />
* Demo compatibility fixes<br />
* Launcher improvements<br />
<br />
A comprehensive list of changes can be found in the CHANGELOG file<br />
shipped with Odamex.<br />
<br />
== Downloads ==<br />
* [https://sourceforge.net/project/showfiles.php?group_id=144102&package_id=158375&release_id=551707 File List for 0.3]<br />
* [http://downloads.sourceforge.net/odamex/odamex-0.3-osx.zip?modtime=1194368610&big_mirror=0 Mac OS X Binaries]<br />
* [http://downloads.sourceforge.net/odamex/Odamex-0.3-win32.zip?modtime=1194135365&big_mirror=0 Windows Binaries]<br />
* [http://downloads.sourceforge.net/odamex/Odamex-0.3-src.tar.bz2?modtime=1194169236&big_mirror=0 Source Code]<br />
<br />
= Odamex 0.2a (r149) =<br />
<br />
= Odamex 0.1a (r33) =</div>Voxelhttps://odamex.net/w/index.php?title=Releases&diff=3142Releases2008-05-24T02:22:33Z<p>Voxel: Odamex 0.3 moved to Releases</p>
<hr />
<div>Odamex 0.3 is the first version to remove the alpha status.<br />
<br />
== Changes since 0.2a ==<br />
A myriad of changes have been added since the previous version, such as:<br />
* Removal of non-free resources<br />
* Cvar and code additions, removals and cleanups<br />
* Single player mode readded<br />
* More bug fixes<br />
* Demo compatibility fixes<br />
* Launcher improvements<br />
<br />
A comprehensive list of changes can be found in the CHANGELOG file<br />
shipped with Odamex.<br />
<br />
== Downloads ==<br />
* [https://sourceforge.net/project/showfiles.php?group_id=144102&package_id=158375&release_id=551707 File List for 0.3]<br />
* [http://downloads.sourceforge.net/odamex/odamex-0.3-osx.zip?modtime=1194368610&big_mirror=0 Mac OS X Binaries]<br />
* [http://downloads.sourceforge.net/odamex/Odamex-0.3-win32.zip?modtime=1194135365&big_mirror=0 Windows Binaries]<br />
* [http://downloads.sourceforge.net/odamex/Odamex-0.3-src.tar.bz2?modtime=1194169236&big_mirror=0 Source Code]</div>Voxelhttps://odamex.net/w/index.php?title=Odamex_0.3&diff=3143Odamex 0.32008-05-24T02:22:33Z<p>Voxel: Odamex 0.3 moved to Releases</p>
<hr />
<div>#redirect [[Releases]]</div>Voxelhttps://odamex.net/w/index.php?title=Coding_standard&diff=3140Coding standard2008-05-22T18:44:21Z<p>Voxel: /* Requirements */</p>
<hr />
<div>==Overview==<br />
Odamex relies on a coding standard to ensure continuity, this reduces bugs and provides easy readability of the code.<br />
<br />
==Requirements==<br />
<br />
* Make logical changes in separate patches<br />
* Minimise the number of changes in each patch<br />
* Provide an off switch for every new feature<br />
* Do not submit things you cannot test (e.g. code for alternative platforms)<br />
<br />
==Code guidelines==<br />
<br />
* Add a [[test]] for every change (or an explanation of why this is impossible)<br />
<br />
Things you should definitely AVOID in your code:<br />
* Changing code that already works<br />
* Precompiler macros<br />
* Global variables (they can create problems elsewhere in code)<br />
* Variants (tagged unions) - they can present a performance problem<br />
* Magic numbers (use #define or const in your code for fixed numbers, at the top of files)<br />
* Hungarian notation (just plan evil)<br />
* C style strings. (replace them with C++ types where it is safe to do so)<br />
* goto<br />
<br />
==Formatting guidelines==<br />
<br />
* If creating a new file, include a GPL header at the top of it, as seen in other files.<br />
* Descriptive comments<br />
* Comments of reasonable size. (not too big and not too small)<br />
* Comment formatting. (in c/c++, either // for 1 liners or /* */ for multiple lines)<br />
* Indentations to be of 1 tab character, using 4 space width tabs<br />
* Be sure your editor/IDE's EOL mode is LF, not CRLF or CR<br />
* 80 line character limit, for devs with text-based editors<br />
* if you can, limit functions to a maximum size (like the amount that would fit on a monitor with a reasonable screen resolution)<br />
<br />
What you should strive for:<br />
* Clarity of code<br />
* Defensive and secure coding practices<br />
* Maintain traditional naming conventions, for consistency<br />
<br />
<br />
<br />
==External Links==<br />
<br />
* [http://www.jwz.org/doc/tabs-vs-spaces.html tabs-vs-spaces]</div>Voxelhttps://odamex.net/w/index.php?title=Coding_standard&diff=3139Coding standard2008-05-22T18:41:31Z<p>Voxel: /* Requirements */</p>
<hr />
<div>==Overview==<br />
Odamex relies on a coding standard to ensure continuity, this reduces bugs and provides easy readability of the code.<br />
<br />
==Requirements==<br />
<br />
* Make logical changes in separate patches<br />
* Minimise the number of changes in each patch<br />
* Provide an off switch for every new feature<br />
* Do not submit things you cannot test (e.g. alternative platforms)<br />
<br />
==Code guidelines==<br />
<br />
* Add a [[test]] for every change (or an explanation of why this is impossible)<br />
<br />
Things you should definitely AVOID in your code:<br />
* Changing code that already works<br />
* Precompiler macros<br />
* Global variables (they can create problems elsewhere in code)<br />
* Variants (tagged unions) - they can present a performance problem<br />
* Magic numbers (use #define or const in your code for fixed numbers, at the top of files)<br />
* Hungarian notation (just plan evil)<br />
* C style strings. (replace them with C++ types where it is safe to do so)<br />
* goto<br />
<br />
==Formatting guidelines==<br />
<br />
* If creating a new file, include a GPL header at the top of it, as seen in other files.<br />
* Descriptive comments<br />
* Comments of reasonable size. (not too big and not too small)<br />
* Comment formatting. (in c/c++, either // for 1 liners or /* */ for multiple lines)<br />
* Indentations to be of 1 tab character, using 4 space width tabs<br />
* Be sure your editor/IDE's EOL mode is LF, not CRLF or CR<br />
* 80 line character limit, for devs with text-based editors<br />
* if you can, limit functions to a maximum size (like the amount that would fit on a monitor with a reasonable screen resolution)<br />
<br />
What you should strive for:<br />
* Clarity of code<br />
* Defensive and secure coding practices<br />
* Maintain traditional naming conventions, for consistency<br />
<br />
<br />
<br />
==External Links==<br />
<br />
* [http://www.jwz.org/doc/tabs-vs-spaces.html tabs-vs-spaces]</div>Voxelhttps://odamex.net/w/index.php?title=Timeline&diff=3138Timeline2008-05-18T17:24:08Z<p>Voxel: /* 2007 */</p>
<hr />
<div>This is a Timeline of events and milestones of the Odamex project, from the founding of Zwango until the present state of the project.<br />
<br />
===2005===<br />
* Odamex's precursor, Zwango, was created and the first binary build was dated July 2nd. The lead programmer was anarkavre and the project leader was Ralphis. The first launcher was developed by Russell, the earliest known build is dated July 5th.<br />
* On August 25th, Zwango was renamed to Odamex by the team.<br />
* Toke programmed CTF into Odamex, first CTF alpha dated September 8th.<br />
* New lead programmer, denis, joins the project on September 23rd.<br />
* SVN Repository created on October 1st.<br />
<br />
===2006===<br />
* Odamex gains initial support of SDL on January 10th, and completely replaces old ZDoom dependencies by January 13th.<br />
* Java launcher is created by AlexMax on January 24th, the first attempt to create a cross-platform launcher.<br />
* Milestone: 500th SVN commit on January 29th.<br />
* Milestone: 1000th SVN commit on February 28th.<br />
* The goal to make Odamex GPL compatible first made progress on March 11th.<br />
* Odamex team member Toke passes away on August 19th.<br />
* Self-zero pointer code introduced on September 26th which significantly reduced crashes and automatically resets servers.<br />
* Manc officially opened the website on October 23rd.<br />
* Milestone: 2000th SVN commit on November 11th.<br />
<br />
===2007===<br />
* On January 14th, the Odamex source was [[http://odamex.net/boards/index.php?topic=69 officially declared GPL compliant.]]<br />
* On January 15th, The private SVN ended with 2125 revisions and the public SVN was turned on.<br />
* On January 19th, the first public binaries of Odamex are posted as "Alpha version 0.1".<br />
* On February 20th, the second public binaries of Odamex are posted as "Alpha version 0.2".<br />
* On November 4th, Odamex "[[Odamex_0.3 |0.3]]" is officially released. The alpha/beta prefix is dumped.<br />
* On November 5th, the results of the first Odamex contest are revealed. The contest was to make a 1-on-1 map for use at Odamex's visit to MAGFest.<br />
<br />
===2008===<br />
* Odamex visits [[http://magfest.org Magfest]] from January 3rd through January 6th. The visit is a viewed as a [[http://youtube.com/watch?v=eM8f1GYYCf8 success]].</div>Voxelhttps://odamex.net/w/index.php?title=Development_roadmap&diff=3137Development roadmap2008-05-18T17:21:52Z<p>Voxel: </p>
<hr />
<div>This section is a roadmap of Odamex, things that should be in at different times. This is a volunteer project. You, as a volunteer, make the decisions, this is merely a rough guide.<br />
<br />
=== Completed features ===<br />
* Console paste<br />
* WAD Switching<br />
* WAD Downloading<br />
* Linux/OSX/BSD/Win32/SPARC compatibility<br />
* CTF<br />
* Network compression<br />
* cvar overrides and server tags<br />
* GPL compatibility<br />
* Spectators<br />
* Vanilla demo playback<br />
* Smooth prediction<br />
<br />
=== In-progress features ===<br />
* Demo recording<br />
* Wallhack protection<br />
* Fully functional co-op gaming<br />
* {{Bug|122}}<br />
* Version notifier<br />
* Crash reporting<br />
* IPv6 support<br />
* Ingame launcher<br />
* Both TCP(no-nagle) and UDP options<br />
* Console select/copy, buffer scroll up/down<br />
* [[accelerated software rendering]]<br />
* [[Multilingual Support]]<br />
* Dual/Tri-head display support, like doom2.exe -left and -right commands<br />
* Bots<br />
* [http://www.teamhellspawn.com/voxels.htm Voxel sprites]<br />
* ...<br />
<br />
== See also ==<br />
* [[Next release]]</div>Voxelhttps://odamex.net/w/index.php?title=Coding_standard&diff=3136Coding standard2008-05-18T17:16:01Z<p>Voxel: </p>
<hr />
<div>==Overview==<br />
Odamex relies on a coding standard to ensure continuity, this reduces bugs and provides easy readability of the code.<br />
<br />
==Requirements==<br />
<br />
* Make logical changes in separate patches<br />
* Minimise the number of changes in each patch<br />
* Provide an off switch for every new feature<br />
<br />
==Code guidelines==<br />
<br />
* Add a [[test]] for every change (or an explanation of why this is impossible)<br />
<br />
Things you should definitely AVOID in your code:<br />
* Changing code that already works<br />
* Precompiler macros<br />
* Global variables (they can create problems elsewhere in code)<br />
* Variants (tagged unions) - they can present a performance problem<br />
* Magic numbers (use #define or const in your code for fixed numbers, at the top of files)<br />
* Hungarian notation (just plan evil)<br />
* C style strings. (replace them with C++ types where it is safe to do so)<br />
* goto<br />
<br />
==Formatting guidelines==<br />
<br />
* If creating a new file, include a GPL header at the top of it, as seen in other files.<br />
* Descriptive comments<br />
* Comments of reasonable size. (not too big and not too small)<br />
* Comment formatting. (in c/c++, either // for 1 liners or /* */ for multiple lines)<br />
* Indentations to be of 1 tab character, using 4 space width tabs<br />
* Be sure your editor/IDE's EOL mode is LF, not CRLF or CR<br />
* 80 line character limit, for devs with text-based editors<br />
* if you can, limit functions to a maximum size (like the amount that would fit on a monitor with a reasonable screen resolution)<br />
<br />
What you should strive for:<br />
* Clarity of code<br />
* Defensive and secure coding practices<br />
* Maintain traditional naming conventions, for consistency<br />
<br />
<br />
<br />
==External Links==<br />
<br />
* [http://www.jwz.org/doc/tabs-vs-spaces.html tabs-vs-spaces]</div>Voxelhttps://odamex.net/w/index.php?title=Map_List&diff=3135Map List2008-05-18T13:18:35Z<p>Voxel: </p>
<hr />
<div>(intro to the map list concept and functionality here)<br />
<br />
===addmap===<br />
Usage: '''addmap (map name) [optional wad name]'''<br />
<br />
Adds a map to the map list with an optional wad to load.<br />
<br />
Note: You do not need to keep specifying the wad after its loaded for each subsequent addmap command, doing this will cause the server to reconnect any clients when the map changes, thus any clients which reconnect, will have their "state" (weapons, ammo, points) reset.<br />
<br />
===clearmaplist===<br />
Usage: '''clearmaplist'''<br />
<br />
Clears the map list. '''WARNING: No request for confirmation. Use at your own risk!'''<br />
<br />
<br />
===forcenextmap===<br />
Usage: '''forcenextmap'''<br />
<br />
Progresses to the next map in the current [[map list]]. Similar to [[nextmap]], only progresses quickly (without intermission).<br />
<br />
<br />
===maplist===<br />
Usage: '''maplist'''<br />
<br />
Displays the entire map list in the console.<br />
<br />
<br />
===nextmap===<br />
Usage: '''nextmap'''<br />
<br />
Progresses to the next map in the current [[map list]]. Similar to [[forcenextmap]], only progresses naturally (with intermission).</div>Voxelhttps://odamex.net/w/index.php?title=Statistics&diff=3134Statistics2008-05-18T13:15:12Z<p>Voxel: </p>
<hr />
<div>{{stub}}<br />
<br />
This place collects interesting statistics about various aspects of the odamex project<br />
<br />
== SVN ==<br />
* See the [http://odamex.org/stats stats] page.<br />
* See the [http://odamex.org/stats2 other stats] page.<br />
<br />
== Website Stats ==<br />
See [http://odamex.net/sitestats Site stats]</div>Voxelhttps://odamex.net/w/index.php?title=Statistics&diff=3133Statistics2008-05-18T13:15:05Z<p>Voxel: </p>
<hr />
<div>{{stub}}<br />
<br />
This place collects interesting statistics about various aspects of the odamex project<br />
<br />
== SVN ==<br />
* See the [http://odamex.org/stats stats] page.<br />
* See the [http://odamex.org/stats2 other stats] page.<br />
<br />
== Website Stats ==<br />
See [http://odamex.net/sitestats Site stats]<br />
<br />
== IRC ==<br />
todo: stats from IRC logs</div>Voxelhttps://odamex.net/w/index.php?title=Statistics&diff=3132Statistics2008-05-18T13:14:04Z<p>Voxel: </p>
<hr />
<div>{{stub}}<br />
<br />
This place collects interesting statistics about various aspects of the odamex project<br />
<br />
== Bugs ==<br />
<br />
todo: stats from bugzilla<br />
<br />
== SVN ==<br />
* See the [http://odamex.org/stats stats] page.<br />
* See the [http://odamex.org/stats2 other stats] page.<br />
<br />
== OdaWiki ==<br />
todo: wiki stats<br />
<br />
== Website Stats ==<br />
See [http://odamex.net/sitestats Site stats]<br />
<br />
== IRC ==<br />
todo: stats from IRC logs</div>Voxelhttps://odamex.net/w/index.php?title=Statistics&diff=3131Statistics2008-05-18T13:05:32Z<p>Voxel: </p>
<hr />
<div>{{stub}}<br />
<br />
This place collects interesting statistics about various aspects of the odamex project<br />
<br />
== Bugs ==<br />
<br />
=== Open and Closed over time ===<br />
todo: stats from bugzilla<br />
<br />
== Code ==<br />
=== Lines of code over revision ===<br />
LOC is not the best indicator of performance and is included here merely for entertainment value. At this rate (1300 revisions in 6 months), the graph suggests that we shall have no code remaining in 26 months! Linuxdoom only has about 45000 lines.<br />
<br />
[[Image:Odamex LinesOfCode.png|none|500x300px|Lines of code over revisions]]<br />
<br />
And no, the lines aren't hand-counted by slaves. We find scripts such as the following to be slightly cheaper for this purpose (and please don't flood the server):<br />
<br />
'''for i in `seq 1 13`; do svn update -r $(echo "$i*100"|bc); echo $(cat $(find . -iname "*.cpp") | wc -l) >> loc; done; cat loc'''<br />
<br />
=== Files ===<br />
todo<br />
<br />
=== Compressed size ===<br />
todo<br />
<br />
== SVN ==<br />
* See the [http://odamex.org/stats stats] page.<br />
* See the [http://odamex.org/stats2 other stats] page.<br />
<br />
== OdaWiki ==<br />
todo: wiki stats<br />
<br />
== Website Stats ==<br />
See [http://odamex.net/sitestats Site stats]<br />
<br />
== IRC ==<br />
todo: stats from IRC logs</div>Voxelhttps://odamex.net/w/index.php?title=How_to_build_from_source&diff=3117How to build from source2008-05-07T04:49:19Z<p>Voxel: </p>
<hr />
<div>Odamex is open source. This means that it is possible to obtain and compile Odamex from source if you so desire. The Odamex team wishes to make this process as painless as possible, therefore detailed instructions for how to build Odamex are provided in this section.<br />
<br />
=Getting the source=<br />
There are two ways to obtain the source to Odamex:<br />
<br />
* [http://odamex.net/ Download] the latest stable version from the official Odamex website<br />
* Get the absolute latest modifications through anonymous [[Subversion]] access<br />
<br />
=Getting required files=<br />
When you download Odamex, it's almost ready to go, right out of the box. However, you need something to compile it with. In addition, Odamex relies on extra libraries in order to function.<br />
<br />
* [[Required Libraries]]<br />
<br />
=Compiling Odamex=<br />
You have all the pieces of the puzzle...now it's time to build.<br />
<br />
Depending on what operating system and hardware you are running, you have many options of compilers. Some of the more popular choices are below:<br />
<br />
==Windows==<br />
===Code::Blocks IDE and MinGW===<br />
This is the prefered method of compiling Odamex on Windows. Code::Blocks project and workspace files are included in the [[Subversion]].<br />
* See [[Compiling using Code::Blocks]]<br />
<br />
===MinGW and MSYS===<br />
This method of compiling utilizes the command line to compile Odamex. This is useful if you prefer not to use an IDE.<br />
* See [[Compiling using MSYS]]<br />
<br />
===Microsoft Visual Studio===<br />
Odamex currently supports compiling under Microsoft Visual C++ 6.0, and a Visual C++ 6.0 project file is included in [[Subversion]]. Support for later versions of Visual Studio is unconfirmed.<br />
* See [[Compiling using Microsoft Visual Studio]]<br />
<br />
===Cygwin and GCC===<br />
Support for native Cygwin binaries is not supported at this time, though is both feasable and desirable in the future. You can, however, compile Odamex without Cygwin support under Cygwin, with minor adjustments, though this is not considered "Cygwin GCC".<br />
* See [[Compiling using GCC]]<br />
<br />
==Linux==<br />
===GCC===<br />
This is the prefered method of compiling Odamex in Linux. Makefiles are included in the [[Subversion]].<br />
* See [[Compiling using GCC]]<br />
<br />
==FreeBSD==<br />
===GCC===<br />
This is the prefered method of compiling Odamex in FreeBSD. Makefiles are included in [[Subversion]], and should work with the FreeBSD version of GNU Make (gmake) and GCC.<br />
* See [[Compiling using GCC]]<br />
<br />
==OSX==<br />
===Xcode===<br />
* See [[Compiling using Xcode]]<br />
<br />
=Cross compiling=<br />
You can build the windows version of odamex on linux:<br />
* See [[Cross compiling for Windows using MinGW]]<br />
<br />
=Compiling the Launcher=<br />
So you want to mess around with the Launcher? Here's how to do it.<br />
<br />
* See [[Compiling the Launcher using Code::Blocks]]<br />
* See [[Compiling the Launcher using GCC]]<br />
<br />
=Building odamex.wad=<br />
This will show you how to build the latest odamex.wad file<br />
<br />
* [[Building odamex.wad using DeuTex]] on multiple platforms<br />
<br />
''Note: odamex.wad gets built automatically when using the Makefile</div>Voxelhttps://odamex.net/w/index.php?title=Test&diff=3106Test2008-05-06T01:51:56Z<p>Voxel: /* TCL Primer */</p>
<hr />
<div>Odamex has a lot of working features. The doom engine is sensitive to change, so to preserve functionality we have a set of tests to run on every submission. They are located in the tests directory.<br />
<br />
==Running tests==<br />
You will need to have [http://tcl.tk/ TCL] installed (free download available from [http://www.activestate.com/store/activetcl/download/ ActiveState])<br />
<br />
===Under Windows===<br />
<br />
You must build odamex as a console application. This is because if you run odamex from the command window (Start, Run: cmd) and it detaches from the command console, the tests will not work.<br />
<br />
Open a command window (Start, Run: cmd). Navigate to your binary directory (the one which contains client and server binaries). Run one of the tests:<br />
<pre><br />
cd trunk\bin<br />
tclsh85 ..\tests\commands\cmdSay.tcl<br />
</pre><br />
<br />
===Under Unix===<br />
You can run all tests with ''make test'', or a specific test by navigating to the working directory and invoking one of the tcl test scripts from there:<br />
<pre><br />
cd trunk<br />
tests/commands/cmdSay.tcl<br />
</pre><br />
<br />
==Writing tests==<br />
Tests are written in [http://tcl.tk TCL] (pronounced ''tickle''), as this is a portable easy to learn scripting language. It is best to start by copying an existing test. Tests should output lines containing the words "PASS" or "FAIL".<br />
<br />
Tests can start/stop clients and servers, send them commands and monitor the output. Complexity of the test increases with the complexity of the feature, this encourages smaller changes.<br />
<br />
==Example==<br />
<br />
<pre><br />
#!/bin/bash<br />
# Do not change these first three lines \<br />
exec tclsh "$0" "$@"<br />
<br />
# Create a list of demos to test (a list of lists of 3 items)<br />
lappend demos "DOOM2.WAD DEMO1 {15eb4720 3ccc7a1 3fc7e27 800000}"<br />
lappend demos "DOOM2.WAD DEMO2 {cea29400 289b9c2 fece4356 600000}"<br />
lappend demos "DOOM2.WAD DEMO3 {dca00040 fd6a4b9c ff7bee0a ff000000}"<br />
<br />
foreach demo $demos {<br />
# Run this demo<br />
set stdout [exec ./odamex -nosound -novideo \<br />
-iwad [lindex $demo 0] \<br />
+demotest [lindex $demo 1]]<br />
<br />
# Take the last line of output<br />
set result [lindex [split $stdout "\n"] end]<br />
<br />
# Take the last item in this demo line (see top of test)<br />
set expected [lindex $demo 2]<br />
<br />
# Compare them<br />
if { $result != $expected} {<br />
puts "FAIL $demo | $result"<br />
} else {<br />
puts "PASS $demo | $result"<br />
}<br />
}<br />
</pre><br />
<br />
==Advanced TCL==<br />
All relevant documentation is easily available on the internet; this section briefly talks about things you are likely to encounter<br />
<br />
===Pipes===<br />
''exec'' is a synchronous command, it will wait for execution to finish before returning control to your script. This is not good when you want to control both a client and a server. What you need is a pipe:<br />
<br />
<pre><br />
set control [open "|./odamex" "w"]<br />
</pre><br />
<br />
Problem is, pipes are one-way (either read only or write only), so you'd need to redirect the output and read it a different manner (after a short delay to allow the output file to be created):<br />
<br />
<pre><br />
set control [open "|./odamex > odamex.log" "w"]<br />
exec sleep 1<br />
set output [open "odamex.log" "r"]<br />
</pre><br />
<br />
And you must remember to close both pipes, but before you do, you must ensure that the application has quit (otherwise ''close'' will never complete). To do this, use ''puts'' to write the quit command to the client (as if it were typed). Applications do not like multiple puts without having the stream flushed, so a ''flush'' follows the ''puts''.<br />
<br />
<pre><br />
set control [open "|./odamex > odamex.log" w]<br />
exec sleep 1<br />
set output [open "odamex.log" r]<br />
<br />
puts $control quit<br />
flush $control<br />
<br />
close $control<br />
close $output<br />
</pre><br />
<br />
Most of this functionality should be put into separate procs so that it does not hurt your head. A lot of it is already available as functions within existing tests, which you can copy.<br />
<br />
==See also==<br />
* [[Coding standard]]</div>Voxelhttps://odamex.net/w/index.php?title=Test&diff=3105Test2008-05-06T01:51:02Z<p>Voxel: /* Under Windows */</p>
<hr />
<div>Odamex has a lot of working features. The doom engine is sensitive to change, so to preserve functionality we have a set of tests to run on every submission. They are located in the tests directory.<br />
<br />
==Running tests==<br />
You will need to have [http://tcl.tk/ TCL] installed (free download available from [http://www.activestate.com/store/activetcl/download/ ActiveState])<br />
<br />
===Under Windows===<br />
<br />
You must build odamex as a console application. This is because if you run odamex from the command window (Start, Run: cmd) and it detaches from the command console, the tests will not work.<br />
<br />
Open a command window (Start, Run: cmd). Navigate to your binary directory (the one which contains client and server binaries). Run one of the tests:<br />
<pre><br />
cd trunk\bin<br />
tclsh85 ..\tests\commands\cmdSay.tcl<br />
</pre><br />
<br />
===Under Unix===<br />
You can run all tests with ''make test'', or a specific test by navigating to the working directory and invoking one of the tcl test scripts from there:<br />
<pre><br />
cd trunk<br />
tests/commands/cmdSay.tcl<br />
</pre><br />
<br />
==Writing tests==<br />
Tests are written in [http://tcl.tk TCL] (pronounced ''tickle''), as this is a portable easy to learn scripting language. It is best to start by copying an existing test. Tests should output lines containing the words "PASS" or "FAIL".<br />
<br />
Tests can start/stop clients and servers, send them commands and monitor the output. Complexity of the test increases with the complexity of the feature, this encourages smaller changes.<br />
<br />
==Example==<br />
<br />
<pre><br />
#!/bin/bash<br />
# Do not change these first three lines \<br />
exec tclsh "$0" "$@"<br />
<br />
# Create a list of demos to test (a list of lists of 3 items)<br />
lappend demos "DOOM2.WAD DEMO1 {15eb4720 3ccc7a1 3fc7e27 800000}"<br />
lappend demos "DOOM2.WAD DEMO2 {cea29400 289b9c2 fece4356 600000}"<br />
lappend demos "DOOM2.WAD DEMO3 {dca00040 fd6a4b9c ff7bee0a ff000000}"<br />
<br />
foreach demo $demos {<br />
# Run this demo<br />
set stdout [exec ./odamex -nosound -novideo \<br />
-iwad [lindex $demo 0] \<br />
+demotest [lindex $demo 1]]<br />
<br />
# Take the last line of output<br />
set result [lindex [split $stdout "\n"] end]<br />
<br />
# Take the last item in this demo line (see top of test)<br />
set expected [lindex $demo 2]<br />
<br />
# Compare them<br />
if { $result != $expected} {<br />
puts "FAIL $demo | $result"<br />
} else {<br />
puts "PASS $demo | $result"<br />
}<br />
}<br />
</pre><br />
<br />
==TCL Primer==<br />
All relevant documentation is easily available on the internet; this section briefly talks about things you are likely to encounter<br />
<br />
===Pipes===<br />
''exec'' is a synchronous command, it will wait for execution to finish before returning control to your script. This is not good when you want to control both a client and a server. What you need is a pipe:<br />
<br />
<pre><br />
set control [open "|./odamex" "w"]<br />
</pre><br />
<br />
Problem is, pipes are one-way (either read only or write only), so you'd need to redirect the output and read it a different manner (after a short delay to allow the output file to be created):<br />
<br />
<pre><br />
set control [open "|./odamex > odamex.log" "w"]<br />
exec sleep 1<br />
set output [open "odamex.log" "r"]<br />
</pre><br />
<br />
And you must remember to close both pipes, but before you do, you must ensure that the application has quit (otherwise ''close'' will never complete). To do this, use ''puts'' to write the quit command to the client (as if it were typed). Applications do not like multiple puts without having the stream flushed, so a ''flush'' follows the ''puts''.<br />
<br />
<pre><br />
set control [open "|./odamex > odamex.log" w]<br />
exec sleep 1<br />
set output [open "odamex.log" r]<br />
<br />
puts $control quit<br />
flush $control<br />
<br />
close $control<br />
close $output<br />
</pre><br />
<br />
Most of this functionality should be put into separate procs so that it does not hurt your head. A lot of it is already available as functions within existing tests, which you can copy.<br />
<br />
==See also==<br />
* [[Coding standard]]</div>Voxelhttps://odamex.net/w/index.php?title=Test&diff=3104Test2008-05-06T01:20:21Z<p>Voxel: /* Pipes */</p>
<hr />
<div>Odamex has a lot of working features. The doom engine is sensitive to change, so to preserve functionality we have a set of tests to run on every submission. They are located in the tests directory.<br />
<br />
==Running tests==<br />
You will need to have [http://tcl.tk/ TCL] installed (free download available from [http://www.activestate.com/store/activetcl/download/ ActiveState])<br />
<br />
===Under Windows===<br />
Open a command window (Start, Run: cmd). Navigate to your binary directory (the one which contains client and server binaries). Run one of the tests:<br />
<pre><br />
cd trunk\bin<br />
tclsh85 ..\tests\commands\cmdSay.tcl<br />
</pre><br />
<br />
===Under Unix===<br />
You can run all tests with ''make test'', or a specific test by navigating to the working directory and invoking one of the tcl test scripts from there:<br />
<pre><br />
cd trunk<br />
tests/commands/cmdSay.tcl<br />
</pre><br />
<br />
==Writing tests==<br />
Tests are written in [http://tcl.tk TCL] (pronounced ''tickle''), as this is a portable easy to learn scripting language. It is best to start by copying an existing test. Tests should output lines containing the words "PASS" or "FAIL".<br />
<br />
Tests can start/stop clients and servers, send them commands and monitor the output. Complexity of the test increases with the complexity of the feature, this encourages smaller changes.<br />
<br />
==Example==<br />
<br />
<pre><br />
#!/bin/bash<br />
# Do not change these first three lines \<br />
exec tclsh "$0" "$@"<br />
<br />
# Create a list of demos to test (a list of lists of 3 items)<br />
lappend demos "DOOM2.WAD DEMO1 {15eb4720 3ccc7a1 3fc7e27 800000}"<br />
lappend demos "DOOM2.WAD DEMO2 {cea29400 289b9c2 fece4356 600000}"<br />
lappend demos "DOOM2.WAD DEMO3 {dca00040 fd6a4b9c ff7bee0a ff000000}"<br />
<br />
foreach demo $demos {<br />
# Run this demo<br />
set stdout [exec ./odamex -nosound -novideo \<br />
-iwad [lindex $demo 0] \<br />
+demotest [lindex $demo 1]]<br />
<br />
# Take the last line of output<br />
set result [lindex [split $stdout "\n"] end]<br />
<br />
# Take the last item in this demo line (see top of test)<br />
set expected [lindex $demo 2]<br />
<br />
# Compare them<br />
if { $result != $expected} {<br />
puts "FAIL $demo | $result"<br />
} else {<br />
puts "PASS $demo | $result"<br />
}<br />
}<br />
</pre><br />
<br />
==TCL Primer==<br />
All relevant documentation is easily available on the internet; this section briefly talks about things you are likely to encounter<br />
<br />
===Pipes===<br />
''exec'' is a synchronous command, it will wait for execution to finish before returning control to your script. This is not good when you want to control both a client and a server. What you need is a pipe:<br />
<br />
<pre><br />
set control [open "|./odamex" "w"]<br />
</pre><br />
<br />
Problem is, pipes are one-way (either read only or write only), so you'd need to redirect the output and read it a different manner (after a short delay to allow the output file to be created):<br />
<br />
<pre><br />
set control [open "|./odamex > odamex.log" "w"]<br />
exec sleep 1<br />
set output [open "odamex.log" "r"]<br />
</pre><br />
<br />
And you must remember to close both pipes, but before you do, you must ensure that the application has quit (otherwise ''close'' will never complete). To do this, use ''puts'' to write the quit command to the client (as if it were typed). Applications do not like multiple puts without having the stream flushed, so a ''flush'' follows the ''puts''.<br />
<br />
<pre><br />
set control [open "|./odamex > odamex.log" w]<br />
exec sleep 1<br />
set output [open "odamex.log" r]<br />
<br />
puts $control quit<br />
flush $control<br />
<br />
close $control<br />
close $output<br />
</pre><br />
<br />
Most of this functionality should be put into separate procs so that it does not hurt your head. A lot of it is already available as functions within existing tests, which you can copy.<br />
<br />
==See also==<br />
* [[Coding standard]]</div>Voxelhttps://odamex.net/w/index.php?title=Test&diff=3103Test2008-05-06T01:14:55Z<p>Voxel: </p>
<hr />
<div>Odamex has a lot of working features. The doom engine is sensitive to change, so to preserve functionality we have a set of tests to run on every submission. They are located in the tests directory.<br />
<br />
==Running tests==<br />
You will need to have [http://tcl.tk/ TCL] installed (free download available from [http://www.activestate.com/store/activetcl/download/ ActiveState])<br />
<br />
===Under Windows===<br />
Open a command window (Start, Run: cmd). Navigate to your binary directory (the one which contains client and server binaries). Run one of the tests:<br />
<pre><br />
cd trunk\bin<br />
tclsh85 ..\tests\commands\cmdSay.tcl<br />
</pre><br />
<br />
===Under Unix===<br />
You can run all tests with ''make test'', or a specific test by navigating to the working directory and invoking one of the tcl test scripts from there:<br />
<pre><br />
cd trunk<br />
tests/commands/cmdSay.tcl<br />
</pre><br />
<br />
==Writing tests==<br />
Tests are written in [http://tcl.tk TCL] (pronounced ''tickle''), as this is a portable easy to learn scripting language. It is best to start by copying an existing test. Tests should output lines containing the words "PASS" or "FAIL".<br />
<br />
Tests can start/stop clients and servers, send them commands and monitor the output. Complexity of the test increases with the complexity of the feature, this encourages smaller changes.<br />
<br />
==Example==<br />
<br />
<pre><br />
#!/bin/bash<br />
# Do not change these first three lines \<br />
exec tclsh "$0" "$@"<br />
<br />
# Create a list of demos to test (a list of lists of 3 items)<br />
lappend demos "DOOM2.WAD DEMO1 {15eb4720 3ccc7a1 3fc7e27 800000}"<br />
lappend demos "DOOM2.WAD DEMO2 {cea29400 289b9c2 fece4356 600000}"<br />
lappend demos "DOOM2.WAD DEMO3 {dca00040 fd6a4b9c ff7bee0a ff000000}"<br />
<br />
foreach demo $demos {<br />
# Run this demo<br />
set stdout [exec ./odamex -nosound -novideo \<br />
-iwad [lindex $demo 0] \<br />
+demotest [lindex $demo 1]]<br />
<br />
# Take the last line of output<br />
set result [lindex [split $stdout "\n"] end]<br />
<br />
# Take the last item in this demo line (see top of test)<br />
set expected [lindex $demo 2]<br />
<br />
# Compare them<br />
if { $result != $expected} {<br />
puts "FAIL $demo | $result"<br />
} else {<br />
puts "PASS $demo | $result"<br />
}<br />
}<br />
</pre><br />
<br />
==TCL Primer==<br />
All relevant documentation is easily available on the internet; this section briefly talks about things you are likely to encounter<br />
<br />
===Pipes===<br />
''exec'' is a synchronous command, it will wait for execution to finish before returning control to your script. This is not good when you want to control both a client and a server. What you need is a pipe:<br />
<br />
<pre><br />
set control [open "|./odamex" "w"]<br />
</pre><br />
<br />
Problem is, pipes are one-way (either read only or write only), so you'd need to redirect the output and read it a different manner (after a short delay to allow the output file to be created):<br />
<br />
<pre><br />
set control [open "|./odamex > odamex.log" "w"]<br />
exec sleep 1<br />
set output [open "odamex.log" "r"]<br />
</pre><br />
<br />
And you must remember to close both pipes, but before you do, you must ensure that the application has quit (otherwise ''close'' will never complete):<br />
<br />
<pre><br />
set control [open "|./odamex > odamex.log" w]<br />
exec sleep 1<br />
set output [open "odamex.log" r]<br />
<br />
puts $control quit<br />
<br />
close $control<br />
close $output<br />
</pre><br />
<br />
==See also==<br />
* [[Coding standard]]</div>Voxelhttps://odamex.net/w/index.php?title=Test&diff=3102Test2008-05-06T00:58:09Z<p>Voxel: /* Under Windows */</p>
<hr />
<div>Odamex has a lot of working features. The doom engine is sensitive to change, so to preserve functionality we have a set of tests to run on every submission. They are located in the tests directory.<br />
<br />
==Running tests==<br />
You will need to have [http://tcl.tk/ TCL] installed (free download available from [http://www.activestate.com/store/activetcl/download/ ActiveState])<br />
<br />
===Under Windows===<br />
Open a command window (Start, Run: cmd). Navigate to your binary directory (the one which contains client and server binaries). Run one of the tests:<br />
<pre><br />
cd trunk\bin<br />
tclsh85 ..\tests\commands\cmdSay.tcl<br />
</pre><br />
<br />
===Under Unix===<br />
You can run all tests with ''make test'', or a specific test by navigating to the working directory and invoking one of the tcl test scripts from there:<br />
<pre><br />
cd trunk<br />
tests/commands/cmdSay.tcl<br />
</pre><br />
<br />
==Writing tests==<br />
Tests are written in [http://tcl.tk TCL] (pronounced ''tickle''), as this is a portable easy to learn scripting language. It is best to start by copying an existing test. Tests should output lines containing the words "PASS" or "FAIL".<br />
<br />
Tests can start/stop clients and servers, send them commands and monitor the output. Complexity of the test increases with the complexity of the feature, this encourages smaller changes.<br />
<br />
==Example==<br />
<br />
<pre><br />
#!/bin/bash<br />
# Do not change these first three lines \<br />
exec tclsh "$0" "$@"<br />
<br />
# Create a list of demos to test (a list of lists of 3 items)<br />
lappend demos "DOOM2.WAD DEMO1 {15eb4720 3ccc7a1 3fc7e27 800000}"<br />
lappend demos "DOOM2.WAD DEMO2 {cea29400 289b9c2 fece4356 600000}"<br />
lappend demos "DOOM2.WAD DEMO3 {dca00040 fd6a4b9c ff7bee0a ff000000}"<br />
<br />
foreach demo $demos {<br />
# Run this demo<br />
set stdout [exec ./odamex -nosound -novideo \<br />
-iwad [lindex $demo 0] \<br />
+demotest [lindex $demo 1]]<br />
<br />
# Take the last line of output<br />
set result [lindex [split $stdout "\n"] end]<br />
<br />
# Take the last item in this demo line (see top of test)<br />
set expected [lindex $demo 2]<br />
<br />
# Compare them<br />
if { $result != $expected} {<br />
puts "FAIL $demo | $result"<br />
} else {<br />
puts "PASS $demo | $result"<br />
}<br />
}<br />
</pre><br />
<br />
==See also==<br />
* [[Coding standard]]</div>Voxelhttps://odamex.net/w/index.php?title=Test&diff=3101Test2008-05-06T00:57:20Z<p>Voxel: /* Under Windows */</p>
<hr />
<div>Odamex has a lot of working features. The doom engine is sensitive to change, so to preserve functionality we have a set of tests to run on every submission. They are located in the tests directory.<br />
<br />
==Running tests==<br />
You will need to have [http://tcl.tk/ TCL] installed (free download available from [http://www.activestate.com/store/activetcl/download/ ActiveState])<br />
<br />
===Under Windows===<br />
Open a command window (Start, Run: cmd). Navigate to your binary directory (the one which contains client and server binaries). Run one of the tests:<br />
<pre><br />
cd trunk\bin<br />
tclsh ..\tests\commands\cmdSay.tcl<br />
</pre><br />
<br />
===Under Unix===<br />
You can run all tests with ''make test'', or a specific test by navigating to the working directory and invoking one of the tcl test scripts from there:<br />
<pre><br />
cd trunk<br />
tests/commands/cmdSay.tcl<br />
</pre><br />
<br />
==Writing tests==<br />
Tests are written in [http://tcl.tk TCL] (pronounced ''tickle''), as this is a portable easy to learn scripting language. It is best to start by copying an existing test. Tests should output lines containing the words "PASS" or "FAIL".<br />
<br />
Tests can start/stop clients and servers, send them commands and monitor the output. Complexity of the test increases with the complexity of the feature, this encourages smaller changes.<br />
<br />
==Example==<br />
<br />
<pre><br />
#!/bin/bash<br />
# Do not change these first three lines \<br />
exec tclsh "$0" "$@"<br />
<br />
# Create a list of demos to test (a list of lists of 3 items)<br />
lappend demos "DOOM2.WAD DEMO1 {15eb4720 3ccc7a1 3fc7e27 800000}"<br />
lappend demos "DOOM2.WAD DEMO2 {cea29400 289b9c2 fece4356 600000}"<br />
lappend demos "DOOM2.WAD DEMO3 {dca00040 fd6a4b9c ff7bee0a ff000000}"<br />
<br />
foreach demo $demos {<br />
# Run this demo<br />
set stdout [exec ./odamex -nosound -novideo \<br />
-iwad [lindex $demo 0] \<br />
+demotest [lindex $demo 1]]<br />
<br />
# Take the last line of output<br />
set result [lindex [split $stdout "\n"] end]<br />
<br />
# Take the last item in this demo line (see top of test)<br />
set expected [lindex $demo 2]<br />
<br />
# Compare them<br />
if { $result != $expected} {<br />
puts "FAIL $demo | $result"<br />
} else {<br />
puts "PASS $demo | $result"<br />
}<br />
}<br />
</pre><br />
<br />
==See also==<br />
* [[Coding standard]]</div>Voxelhttps://odamex.net/w/index.php?title=Test&diff=3100Test2008-05-06T00:46:09Z<p>Voxel: /* Running tests */</p>
<hr />
<div>Odamex has a lot of working features. The doom engine is sensitive to change, so to preserve functionality we have a set of tests to run on every submission. They are located in the tests directory.<br />
<br />
==Running tests==<br />
You will need to have [http://tcl.tk/ TCL] installed (free download available from [http://www.activestate.com/store/activetcl/download/ ActiveState])<br />
<br />
===Under Windows===<br />
Open a command window (Start, Run: cmd). Navigate to your working directory (the one which contains client, server and common folders). Run one of the tests:<br />
<pre><br />
cd trunk<br />
tests\commands\cmdSay.tcl<br />
</pre><br />
<br />
===Under Unix===<br />
You can run all tests with ''make test'', or a specific test by navigating to the working directory and invoking one of the tcl test scripts from there:<br />
<pre><br />
cd trunk<br />
tests/commands/cmdSay.tcl<br />
</pre><br />
<br />
==Writing tests==<br />
Tests are written in [http://tcl.tk TCL] (pronounced ''tickle''), as this is a portable easy to learn scripting language. It is best to start by copying an existing test. Tests should output lines containing the words "PASS" or "FAIL".<br />
<br />
Tests can start/stop clients and servers, send them commands and monitor the output. Complexity of the test increases with the complexity of the feature, this encourages smaller changes.<br />
<br />
==Example==<br />
<br />
<pre><br />
#!/bin/bash<br />
# Do not change these first three lines \<br />
exec tclsh "$0" "$@"<br />
<br />
# Create a list of demos to test (a list of lists of 3 items)<br />
lappend demos "DOOM2.WAD DEMO1 {15eb4720 3ccc7a1 3fc7e27 800000}"<br />
lappend demos "DOOM2.WAD DEMO2 {cea29400 289b9c2 fece4356 600000}"<br />
lappend demos "DOOM2.WAD DEMO3 {dca00040 fd6a4b9c ff7bee0a ff000000}"<br />
<br />
foreach demo $demos {<br />
# Run this demo<br />
set stdout [exec ./odamex -nosound -novideo \<br />
-iwad [lindex $demo 0] \<br />
+demotest [lindex $demo 1]]<br />
<br />
# Take the last line of output<br />
set result [lindex [split $stdout "\n"] end]<br />
<br />
# Take the last item in this demo line (see top of test)<br />
set expected [lindex $demo 2]<br />
<br />
# Compare them<br />
if { $result != $expected} {<br />
puts "FAIL $demo | $result"<br />
} else {<br />
puts "PASS $demo | $result"<br />
}<br />
}<br />
</pre><br />
<br />
==See also==<br />
* [[Coding standard]]</div>Voxelhttps://odamex.net/w/index.php?title=Test&diff=3099Test2008-05-06T00:45:16Z<p>Voxel: /* Running tests */</p>
<hr />
<div>Odamex has a lot of working features. The doom engine is sensitive to change, so to preserve functionality we have a set of tests to run on every submission. They are located in the tests directory.<br />
<br />
==Running tests==<br />
You will need to have [http://tcl.tk/ TCL binaries] installed (free download available from [http://www.activestate.com/store/activetcl/download/ ActiveState])<br />
<br />
===Under Windows===<br />
Open a command window (Start, Run: cmd). Navigate to your working directory (the one which contains client, server and common folders). Run one of the tests:<br />
<pre><br />
cd trunk<br />
tests\commands\cmdSay.tcl<br />
</pre><br />
<br />
===Under Unix===<br />
You can run all tests with ''make test'', or a specific test by navigating to the working directory and invoking one of the tcl test scripts from there:<br />
<pre><br />
cd trunk<br />
tests/commands/cmdSay.tcl<br />
</pre><br />
<br />
==Writing tests==<br />
Tests are written in [http://tcl.tk TCL] (pronounced ''tickle''), as this is a portable easy to learn scripting language. It is best to start by copying an existing test. Tests should output lines containing the words "PASS" or "FAIL".<br />
<br />
Tests can start/stop clients and servers, send them commands and monitor the output. Complexity of the test increases with the complexity of the feature, this encourages smaller changes.<br />
<br />
==Example==<br />
<br />
<pre><br />
#!/bin/bash<br />
# Do not change these first three lines \<br />
exec tclsh "$0" "$@"<br />
<br />
# Create a list of demos to test (a list of lists of 3 items)<br />
lappend demos "DOOM2.WAD DEMO1 {15eb4720 3ccc7a1 3fc7e27 800000}"<br />
lappend demos "DOOM2.WAD DEMO2 {cea29400 289b9c2 fece4356 600000}"<br />
lappend demos "DOOM2.WAD DEMO3 {dca00040 fd6a4b9c ff7bee0a ff000000}"<br />
<br />
foreach demo $demos {<br />
# Run this demo<br />
set stdout [exec ./odamex -nosound -novideo \<br />
-iwad [lindex $demo 0] \<br />
+demotest [lindex $demo 1]]<br />
<br />
# Take the last line of output<br />
set result [lindex [split $stdout "\n"] end]<br />
<br />
# Take the last item in this demo line (see top of test)<br />
set expected [lindex $demo 2]<br />
<br />
# Compare them<br />
if { $result != $expected} {<br />
puts "FAIL $demo | $result"<br />
} else {<br />
puts "PASS $demo | $result"<br />
}<br />
}<br />
</pre><br />
<br />
==See also==<br />
* [[Coding standard]]</div>Voxel