mirror of
https://github.com/GameServerManagers/LinuxGSM.git
synced 2025-01-08 12:07:37 +08:00
feat(bfv): add query for bfv (#4740)
* fix quake2 and formatted * correct bfv ports * update bf config info * remove curl * tidy * fix jc2mp query name
This commit is contained in:
parent
06166045bc
commit
f49c2b3aa7
@ -123,8 +123,8 @@ stopmode="3"
|
||||
# 3: gamedig
|
||||
# 4: gsquery
|
||||
# 5: tcp
|
||||
querymode="1"
|
||||
querytype=""
|
||||
querymode="3"
|
||||
querytype="protocol-gamespy2"
|
||||
|
||||
## Console type
|
||||
consoleverbose="yes"
|
||||
|
@ -134,7 +134,7 @@ stopmode="2"
|
||||
# 4: gsquery
|
||||
# 5: tcp
|
||||
querymode="2"
|
||||
querytype="jc2m"
|
||||
querytype="jc2mp"
|
||||
|
||||
## Console type
|
||||
consoleverbose="yes"
|
||||
|
@ -959,13 +959,14 @@ fn_info_game_bf1942() {
|
||||
fn_info_game_keyvalue_pairs_space "configip" "game.serverIP"
|
||||
fn_info_game_keyvalue_pairs_space "maxplayers" "game.serverMaxPlayers"
|
||||
fn_info_game_keyvalue_pairs_space "port" "game.serverPort"
|
||||
fn_info_game_keyvalue_pairs_space "queryport" "game.gameSpyPort"
|
||||
fn_info_game_keyvalue_pairs_space "servername" "game.serverName"
|
||||
fn_info_game_keyvalue_pairs_space "serverpassword" "game.serverPassword"
|
||||
fi
|
||||
configip="${configip:-"0.0.0.0"}"
|
||||
maxplayers="${maxplayers:-"0"}"
|
||||
port="${port:-"0"}"
|
||||
queryport="22000"
|
||||
queryport="${queryport:-"0"}"
|
||||
servername="${servername:-"NOT SET"}"
|
||||
serverpassword="${serverpassword:-"NOT SET"}"
|
||||
}
|
||||
@ -982,11 +983,12 @@ fn_info_game_bfv() {
|
||||
fn_info_game_keyvalue_pairs_space "port" "game.serverPort"
|
||||
fn_info_game_keyvalue_pairs_space "servername" "game.serverName"
|
||||
fn_info_game_keyvalue_pairs_space "serverpassword" "game.serverPassword"
|
||||
fn_info_game_keyvalue_pairs_space "queryport" "game.gameSpyPort"
|
||||
fi
|
||||
configip="${configip:-"0.0.0.0"}"
|
||||
maxplayers="${maxplayers:-"0"}"
|
||||
port="${port:-"0"}"
|
||||
queryport="22000"
|
||||
queryport="${queryport:-"0"}"
|
||||
servername="${servername:-"NOT SET"}"
|
||||
serverpassword="${serverpassword:-"NOT SET"}"
|
||||
}
|
||||
|
@ -11,7 +11,7 @@ import socket
|
||||
import sys
|
||||
|
||||
engine_types = ('protocol-valve', 'protocol-quake2', 'protocol-quake3', 'protocol-gamespy1',
|
||||
'protocol-unreal2', 'ut3', 'minecraft', 'minecraftbe', 'jc2m', 'mumbleping', 'soldat', 'teeworlds')
|
||||
'protocol-unreal2', 'ut3', 'minecraft', 'minecraftbe', 'jc2mp', 'mumbleping', 'soldat', 'teeworlds')
|
||||
|
||||
|
||||
class gsquery:
|
||||
@ -22,11 +22,11 @@ class gsquery:
|
||||
idtech2query = ('protocol-quake2', 'idtech2', 'quake', 'iw2.0')
|
||||
idtech3query = ('protocol-quake3', 'iw3.0', 'ioquake3', 'qfusion')
|
||||
minecraftquery = ('minecraft', 'lwjgl2')
|
||||
minecraftbequery = ('minecraftbe',)
|
||||
jc2mquery = ('jc2m',)
|
||||
mumblequery = ('mumbleping',)
|
||||
soldatquery = ('soldat',)
|
||||
twquery = ('teeworlds',)
|
||||
minecraftbequery = ('minecraftbe')
|
||||
jc2mpquery = ('jc2mp')
|
||||
mumblequery = ('mumbleping')
|
||||
soldatquery = ('soldat')
|
||||
twquery = ('teeworlds')
|
||||
unrealquery = ('protocol-gamespy1', 'unreal')
|
||||
unreal2query = ('protocol-unreal2', 'unreal2')
|
||||
unreal3query = ('ut3', 'unreal3')
|
||||
@ -40,7 +40,7 @@ class gsquery:
|
||||
self.query_prompt_string = b'\xff\xff\xff\xffstatus\x00'
|
||||
elif self.argument.engine in self.idtech3query:
|
||||
self.query_prompt_string = b'\xff\xff\xff\xffgetstatus'
|
||||
elif self.argument.engine in self.jc2mquery:
|
||||
elif self.argument.engine in self.jc2mpquery:
|
||||
self.query_prompt_string = b'\xFE\xFD\x09\x10\x20\x30\x40'
|
||||
elif self.argument.engine in self.minecraftquery:
|
||||
self.query_prompt_string = b'\xFE\xFD\x09\x3d\x54\x1f\x93'
|
||||
|
Loading…
Reference in New Issue
Block a user