There are currently 19 entity commands in total, but only the first 6 possible (depends on the active selection, e.g. patrolling isn't possible if no units are selected) ones are ever displayed as buttons (defined by g_SelectionPanels.Command.getMaxNumberOfItems) However, when updating (once per turn or whenever the selection changes), g_SelectionPanels.Command.getItems always called `getInfo` on all of them, even though all data computed after the first 6 wasn't read or used anywhere later. So, stopping immediately after the 6th and never returning an array longer than 6 saves all of the dead time without affecting the outcome in any way. It's important to mention, that this issue isn't exclusive to the 'Command' selection panel: the getItems methods of the other panels can also return an array longer than their getMaxNumbertOfItems value (that's why they specify it in the first place). However, for the command panel this happens for many common selections and seemingly to by far the largest extent. For the other panels it happens much more rarely, only for especially large and obscure selections, and even then does not have nearly as big of an impact. So, modifying the other getItems methods as well (to never return too many items) is probably not worth it, and the more robust solution is to instead keep the safeguard system of getMaxNumbertOfItems. |
||
|---|---|---|
| .gitea | ||
| binaries | ||
| build | ||
| docs | ||
| libraries | ||
| source | ||
| .editorconfig | ||
| .gitattributes | ||
| .gitignore | ||
| .groovylintrc.json | ||
| .lfsconfig | ||
| .markdownlint.yaml | ||
| .pre-commit-config.yaml | ||
| .shellcheckrc | ||
| .yamllint.yaml | ||
| eslint.config.mjs | ||
| LICENSE.md | ||
| license_dbghelp.txt | ||
| license_gpl-2.0.txt | ||
| license_lgpl-2.1.txt | ||
| license_mit.txt | ||
| package.json | ||
| README.md | ||
| ruff.toml | ||
0 A.D. Introductory Information
0 A.D. (pronounced "zero ey-dee") is a free, open-source, cross-platform real-time strategy game of ancient warfare.
This is currently an incomplete, under-development version of the game. We're always interested in getting more people involved, to help bring the game towards completion and to share the interesting experience of developing a project of this scope.
There are several ways to contact us and find more information:
- Web site: https://play0ad.com/
- Forums: https://www.wildfiregames.com/forum/
- Gitea (development info, bug tracker): https://gitea.wildfiregames.com/
- IRC: #0ad on irc.quakenet.org
Running precompiled binaries on Windows
A precompiled, ready-to-play development version of the game is available from
a checkout of the nightly-build SVN repository. If you are using the git
repository, you have to follow the steps below.
In a checkout of the nightly-build SVN repository, open the "binaries\system" folder.
- To launch the game: Run pyrogenesis.exe
- To launch the map editor: Run Atlas.bat or "pyrogenesis.exe -editor"
Compiling the game from source code
The instructions for compiling the game on Windows, Linux and OS X are at BuildInstructions.
Reporting problems
Bugs should be reported on Gitea. For information on reporting problems and finding logs, see ReportingErrors.
Contributing Code
If you want to help out programming for the game, have a look at GettingStartedProgrammers or contact us on #0ad-dev on irc.quakenet.org
Contributing Artwork
If you want to make artwork for the game, have a look at For Artists or visit the forums.
Translating
You can help translating the game at https://www.transifex.com/projects/p/0ad for more information, see Localization