fix m_start
This commit is contained in:
parent
cf8c255419
commit
0a95e56a2c
2
hlna.py
2
hlna.py
@ -241,7 +241,6 @@ def start(map_server=list_config):
|
||||
except:
|
||||
print("Неправильный ввод")
|
||||
|
||||
|
||||
for j in str(map_list):
|
||||
map_choise.append(map_server[int(j) - 1])
|
||||
map_server = map_choise
|
||||
@ -252,6 +251,7 @@ def start(map_server=list_config):
|
||||
print_line("Качаем карту: " + i)
|
||||
os.system(f"steamcmd +force_install_dir {dir_server + i} +login anonymous +app_update 376030 +quit")
|
||||
print_line("Карта скачана: " + i)
|
||||
|
||||
def start(i):
|
||||
os.chdir(dir_server + i + "/ShooterGame/Binaries/Linux/")
|
||||
os.system(f"./ShooterGameServer {i}?SessionName={name_server}?Port={port_server}?QueryPort={query_port}?MaxPlayers={max_players}?GameModIds={mods_id}?listen={listen_server} -clusterid={cluster_id} -ClusterDirOverride={cluster_dir_ovverride}")
|
||||
|
@ -13,7 +13,7 @@ map_server = hlna.list_config
|
||||
|
||||
|
||||
@hlna_bot.message_handler(commands=["start"])
|
||||
def start(m):
|
||||
def m_start(m):
|
||||
menu = types.ReplyKeyboardMarkup(resize_keyboard=True)
|
||||
k_start = types.KeyboardButton("🦖 Старт")
|
||||
k_stop = types.KeyboardButton("🦇 Выключить")
|
||||
@ -47,7 +47,7 @@ def m_chose(m):
|
||||
menu_start.add(k_back)
|
||||
hlna_bot.send_message(m.chat.id, text="{0.first_name}, выбери карту".format(m.from_user), reply_markup=menu_start)
|
||||
elif m.text.strip() == 'Назад':
|
||||
hlna_bot.register_next_step_handler(m, start)
|
||||
m_start(m)
|
||||
elif m.text.strip() == 'TheIsland':
|
||||
hlna.start()
|
||||
#def m_start(m):
|
||||
|
Loading…
Reference in New Issue
Block a user