mirror of
https://github.com/tribufu/rust-gamedig
synced 2026-06-01 09:42:41 +00:00
Documentation update
This commit is contained in:
parent
40912bb192
commit
00ead6d946
13 changed files with 117 additions and 58 deletions
|
|
@ -1,16 +1,12 @@
|
|||
use crate::errors::GDError;
|
||||
use crate::valve::{ValveProtocol, App, GatheringSettings, Response};
|
||||
|
||||
pub struct CSGO;
|
||||
|
||||
impl CSGO {
|
||||
pub fn query(address: &str, port: Option<u16>) -> Result<Response, GDError> {
|
||||
ValveProtocol::query(App::CSGO, address, match port {
|
||||
None => 27015,
|
||||
Some(port) => port
|
||||
}, GatheringSettings {
|
||||
players: true,
|
||||
rules: true
|
||||
})
|
||||
}
|
||||
pub fn query(address: &str, port: Option<u16>) -> Result<Response, GDError> {
|
||||
ValveProtocol::query(App::CSGO, address, match port {
|
||||
None => 27015,
|
||||
Some(port) => port
|
||||
}, GatheringSettings {
|
||||
players: true,
|
||||
rules: true
|
||||
})
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue