Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion doc/site/content/articles/team-terminology.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ A "skirmish" AI is hosted by one of the players and generally acts very similar
It can read the game state via AI interface and works by giving units commands.
Strictly speaking, it is their hosting player relaying commands - this means that this type of AI is subject to lag and will drop if the hosting player quits.
On the other hand, only the host player is taking on the burden of simulating the AI.
There are currently Skirmish AI bindings for C and Java (though distributing the Java runtime environment for a Java skirmish AI is up to the game).
There are currently Skirmish AI bindings available in C and C++.
A game does not need explicit support for this kind of AI (meaning for example, somebody can homebrew one), though it will likely want to handle distribution and infrastructure issues (for example to block homebrew AI).

A Lua AI generally has two components: a piece of game mechanics, and the AI instance itself which is just a handle to tell game mechanics which teams are legal to control.
Expand Down
6 changes: 5 additions & 1 deletion rts/System/LoadSave/DemoFileExtension.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,12 @@
#include <zlib.h>

#include "demofile.h"
#include "System/Config/ConfigHandler.h"
#include "System/StringUtil.h"

// Tools do not link the config subsystem, and accept any extension anyway.
#ifndef TOOLS
#include "System/Config/ConfigHandler.h"

CONFIG(std::string, DemoFileExtension).defaultValue("sdfz").description("Comma-separated list of replay file extensions. The first entry is used when recording; all entries are accepted when loading. Set by the lobby (e.g. 'barreplay,sdfz' for BAR).");

std::vector<std::string> GetDemoFileExtensions()
Expand All @@ -32,6 +35,7 @@ std::vector<std::string> GetDemoFileExtensions()
extensions.emplace_back("sdfz");
return extensions;
}
#endif

bool IsDemoExtension(const std::string& ext)
{
Expand Down
3 changes: 2 additions & 1 deletion rts/System/LoadSave/DemoReader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@
#include "Game/GameVersion.h"
#include "Sim/Misc/GlobalConstants.h"

#ifndef TOOLS
#include "DemoFileExtension.h"

#ifndef TOOLS
#include "System/Config/ConfigHandler.h"
CONFIG(bool, DisableDemoVersionCheck).defaultValue(false).description("Allow to play every replay file (may crash / cause undefined behaviour in replays)");
#endif
Expand Down
1 change: 1 addition & 0 deletions tools/DemoTool/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ set(demoToolSpringSources
${ENGINE_SRC_ROOT_DIR}/System/Sync/SHA512.cpp
${ENGINE_SRC_ROOT_DIR}/System/StringUtil.cpp
${ENGINE_SRC_ROOT_DIR}/System/Net/RawPacket.cpp
${ENGINE_SRC_ROOT_DIR}/System/LoadSave/DemoFileExtension.cpp
${ENGINE_SRC_ROOT_DIR}/System/LoadSave/DemoReader.cpp
${ENGINE_SRC_ROOT_DIR}/System/LoadSave/Demo.cpp
${ENGINE_SRC_ROOT_DIR}/System/Log/Backend.cpp
Expand Down