Games: Age of Chivalry support.

This commit is contained in:
CosminPerRam 2023-01-16 23:10:16 +02:00
parent 9c9a096b16
commit e2f42008b2
6 changed files with 20 additions and 1 deletions

12
src/games/aoc.rs Normal file
View file

@ -0,0 +1,12 @@
use crate::GDResult;
use crate::protocols::valve;
use crate::protocols::valve::{game, SteamID};
pub fn query(address: &str, port: Option<u16>) -> GDResult<game::Response> {
let valve_response = valve::query(address, match port {
None => 27015,
Some(port) => port
}, SteamID::AOC.as_app(), None, None)?;
Ok(game::Response::new_from_valve_response(valve_response))
}

View file

@ -65,3 +65,5 @@ pub mod bat1944;
pub mod bm;
/// Project Zomboid
pub mod pz;
/// Age of Chivalry
pub mod aoc;

View file

@ -169,6 +169,8 @@ pub enum SteamID {
TS = 2400,
/// Garry's Mod
GM = 4000,
/// Age of Chivalry
AOC = 17510,
/// Insurgency: Modern Infantry Combat
INSMIC = 17700,
/// ARMA 2: Operation Arrowhead