Skip to content

Commit

Permalink
add lang, fix check leave
Browse files Browse the repository at this point in the history
  • Loading branch information
WessTorn committed Jan 20, 2024
1 parent 6760ce9 commit 3268cee
Show file tree
Hide file tree
Showing 10 changed files with 116 additions and 91 deletions.
22 changes: 21 additions & 1 deletion data/lang/match_additons.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,16 @@ HNS_OWNAGE = %n owned %n's head!

STATS_TOP = %s Show top — ^3/top

MAPS_NOM = %s ^3%n^1 nominated map: ^3%s^1.

HUD_ON = %s HUD info is now ^3enabled^1.
HUD_OFF = %s HUD info is now ^3disabled^1.

DMG_SPAM = %s Please wait ^3%.1f^1 seconds between commands!
DMG_ERR = %s There is no OR multiple players with matching pattern -> ^3%s^1.
DMG_SHOW_ROUND = %s ^3%n^1's fall damage ^3%.0f^1 HP - before ^3%.0f^1 - ^3This round^1 HP, ^3%.1f^1 seconds ago.
DMG_SHOW = %s ^3%n^1's fall damage ^3%.0f^1 HP - before ^3%.0f^1 - ^3Not this round^1 HP, ^3%.1f^1 seconds ago.

[ru]

PTS_RANK = %s Ваш ранг: ^3%d^1 (Птс: ^3%d^1 | Побед: ^3%d^1 | Поражений: ^3%d^1 | Скилл: ^3%s^1)
Expand Down Expand Up @@ -111,4 +121,14 @@ TRNING_DMG = %s Вы получили ^3%i^1 урона.
HNS_OWNAGE_MIX = %n запрыгнул на голову %n! [#%d]
HNS_OWNAGE = %n запрыгнул на голову %n!

STATS_TOP = %s Показать топ — ^3/top
STATS_TOP = %s Показать топ — ^3/top

MAPS_NOM = %s ^3%n^1 номинировал карту: ^3%s^1.

HUD_ON = %s HUD информация ^3включена^1.
HUD_OFF = %s HUD информация^3выключена^1.

DMG_SPAM = %s Пожалуйста, подождите ^3%.1f^1 секунды между командами!
DMG_ERR = %s Не существует ИЛИ нескольких игроков с совпадающим шаблоном -> ^3%s^1.
DMG_SHOW_ROUND = Урон от падения %s ^3%n^1 ^3%.0f^1 HP - до ^3%.0f^1 - ^3Этот раунд^1 HP, ^3%.1f^1 секунд назад.
DMG_SHOW = Урон от падения %s ^3%n^1 ^3%.0f^1 HP - до ^3%.0f^1 - ^3Не этот раунд^1 HP, ^3%.1f^1 секунд назад.
100 changes: 41 additions & 59 deletions data/lang/mixsystem.txt
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
[en]
STATUS_NOPLAY = ^3%n^1 is ^3not available^1 for pick [^3NOPLAY^1]
STATUS_PLAY = ^3%n^1 is now ^3available^1 for pick [^3PLAY^1]

STATUS_NOPLAY = ^3%n^1 is ^3not available^1 for pick. [^3NOPLAY^1]
STATUS_PLAY = ^3%n^1 is now ^3available^1 for pick. [^3PLAY^1]

SET_ROUNDTIME = ^3%n^1 set ^3roundtime^1 to ^3%.2f^1 minutes.
SET_MAXROUNDS = ^3%n^1 set ^3maxrounds^1 to ^3%d^1 (^3%d^1 rounds).
SET_WINTIME = ^3%n^1 set ^3wintime^1 to ^3%d^1 minutes.

KILL_HIMSELF = ^3%n^1 killed himself
KILL_HIMSELF = ^3%n^1 killed himself.
KILL_NOT = Kill during deathmatch is not available.
KILL_NOT_MIX = You need to play ^31.5^1 minutes to kill yourself.

Expand All @@ -15,7 +16,7 @@ SUR_PLAYER = Player ^3%n^1 (^3%s^1) started vote for surrender!
SUR_NEED = Need ^3%d/%d^1 votes for surrender!
SUR_END = Team ^3%s^1 surrendered!

AFK_PAUSE = ^3%d^1 players AFK, pausing game
AFK_PAUSE = ^3%d^1 players AFK, pausing game.
AFK_UNPAUSE = LIVE! All players is here! Unpausing match.

NEED_PAUSE = Match paused, need ^3%d^1 players.
Expand Down Expand Up @@ -44,47 +45,42 @@ DM_CANC = Please disable other mode before deathmatch.

BLEND_TEAMS = ^3%n^1 blend teams.

TRANSF_SPEC = ^3%n^1 transfered all players to ^3spectators
TRANSF_TT = ^3%n^1 transfered all players to ^3terrorist's
TRANSF_CT = ^3%n^1 transfered all players to ^3counter-terrorist's

TYPE_SKILL = ^3%n^1 has activated ^3skill^1 mode
TYPE_BOOST = ^3%n^1 has activated ^3boost^1 mode

AA_10 = ^3%n^1 changed ^3airaccelerate^1 to ^310
AA_100 = ^3%n^1 changed ^3airaccelerate^1 to ^3100
TRANSF_SPEC = ^3%n^1 transfered all players to ^3spectators^1!
TRANSF_TT = ^3%n^1 transfered all players to ^3terrorist's^1!
TRANSF_CT = ^3%n^1 transfered all players to ^3counter-terrorist's^1!

SHOW_KNIFEON = Knife is now set ^3visible.
SHOW_KNIFEOFF = Knife is now set ^3invisible.
TYPE_SKILL = ^3%n^1 has activated ^3skill^1 mode.
TYPE_BOOST = ^3%n^1 has activated ^3boost^1 mode.

AA_10 = ^3%n^1 changed ^3airaccelerate^1 to ^310^1.
AA_100 = ^3%n^1 changed ^3airaccelerate^1 to ^3100^1.

NOT_START_MIX = Please disable other mode before start mix
NOT_START_KNIFE = Please disable other mode before start knife round
NOT_START_MIX = Please disable other mode before start mix.
NOT_START_KNIFE = Please disable other mode before start knife round.

KNIFE_ALREADY = Knife round has already started.

NOT_CAPTAIN = Only available on the knife map.

START_MIX = ^3%n^1 has started ^3mix
START_MIX = ^3%n^1 has started ^3mix^1.
START_KNIFE = Started ^3knife^1 round!

STOP_MIX = ^3%n^1 stopped ^3mix
STOP_KNIFE = ^3%n^1 stopped ^3knife^1 round
STOP_PUB = ^3%n^1 stopped ^3public^1 mode
STOP_CAP = ^3%n^1 stopped ^3captain^1 mode
STOP_DM = ^3%n^1 stopped ^3deathmatch^1 mode
STOP_MIX = ^3%n^1 stopped ^3mix^1.
STOP_KNIFE = ^3%n^1 stopped ^3knife^1 round^1.
STOP_PUB = ^3%n^1 stopped ^3public^1 mode^1.
STOP_CAP = ^3%n^1 stopped ^3captain^1 mode^1.
STOP_DM = ^3%n^1 stopped ^3deathmatch^1 mode^1.

SCORE_TIME = TT [^3%s^1] %d vs %d [^3%s^1] CT (^3%d^1/^3%d^1 rounds) (^3%s^1 diff)
SCORE_TIME_WT = TT [^3%s^1] vs [^3%s^1] CT (^3%s^1 diff)
SCORE_DUEL = Score: TT - ^3%d^1 vs ^3%d^1 - CT
SCORE_NOT = Sorry, but game ain't started atm
SCORE_NOT = Sorry, but game ain't started atm.

SAME_TIMER = Same Timers! OVERTIME! Playing +2 Rounds
SAME_TIMER = Same Timers! OVERTIME! Playing +2 Rounds.

TT_WIN = TT win the match! (^3%s^1 difference)
MR_WIN = %s win the match! (^3%s^1 difference)
DUEL_WIN = Player ^3%n^1 (^3TT^1) win duel!
SHOW_TOP = Show top (^3/top^1)

CAP_CHOOSE = ^3%n^1 choosing captains...
CAP_FIRST = First captain: ^3%n^1.
Expand All @@ -97,28 +93,23 @@ TEAM_FULL = The teams are full!
PLAYER_CHOOSE = Captain ^3%n^1 choose ^3%n^1.
PLAYER_CHOOSE_PTS = Captain ^3%n^1 choose ^3%n^1 (^3%d^1 [^3%s^1]).

TRAINING_NOTALIVE = You must be alive to use this command!
CP_NOTALIVE = You must be alive to use checkpoints!
CP_SAVE = Checkpoint saved!
CP_NOT = You haven't got any checkpoints!
CP_NOTSTUCK = You must have another checkpoint to use stuck!
DAMAGE_INFO = You have taken ^3%i^1 damage.

HUD_TIMETOWIN = Last Round!^n TT Need %s Time to Win!
HUD_CAPWIN = Captain %n win!
HUD_KF_WIN_TT = Team TT won the knife round!
HUD_KF_WIN_CT = Team CT won the knife round!
HUD_START_WAIT = %s^nWaiting for %d players.
HUD_START_LAST = LAST SECONDS BEFORE THE START.
HUD_GAMEOVER = Game Over
HUD_WIN_CT = CT won! ^n TT didn't have enough %s to win! ^n(More than roundtime)
HUD_WIN_TT = TT Win! ^n TT's timer is less than TT's team!
HUD_STARTMIX1 = Going Live in 3 second!
HUD_STARTMIX2 = Live! Live! Live!^nGood Luck & Have Fun!
HUD_STARTKNIFE = Team knife round started.
HUD_UNPAUSE = Game Unpause^nLive! Live! Live!
HUD_PAUSE = GAME PAUSE
HUD_START_CAPKF = Captain knife round started.

NOCLIP_ON = No Clip ^3enabled^1!
NOCLIP_OFF = No Clip ^3disabled^1!
DAMAGE_ON = Damage show ^3enabled^1.
DAMAGE_OFF = Damage show ^3disabled^1.

MENU_MIX_TITLE = \rHide'n'Seek match system
MENU_MAIN_CAP = Start captain mode
MENU_MAIN_NOTCAP = \dStart captain mode
Expand Down Expand Up @@ -225,18 +216,15 @@ DM_CANC = Пожалуйста, отключите другой режи

BLEND_TEAMS = ^3%n^1 смешал команды.

TRANSF_SPEC = ^3%n^1 перевел всех игроков за ^3наблюдателей
TRANSF_TT = ^3%n^1 перевел всех игроков за ^3террористов
TRANSF_CT = ^3%n^1 перевел всех игроков за ^3контр-3террористов

TYPE_SKILL = ^3%n^1 активировал ^3скилл^1 режим
TYPE_BOOST = ^3%n^1 активировал ^3буст^1 режим
TRANSF_SPEC = ^3%n^1 перевел всех игроков за ^3наблюдателей^1!
TRANSF_TT = ^3%n^1 перевел всех игроков за ^3террористов^1!
TRANSF_CT = ^3%n^1 перевел всех игроков за ^3контр-3террористов^1!

AA_10 = ^3%n^1 установил ^3airaccelerate^1 на ^310
AA_100 = ^3%n^1 установил ^3airaccelerate^1 на ^3100
TYPE_SKILL = ^3%n^1 активировал ^3скилл^1 режим.
TYPE_BOOST = ^3%n^1 активировал ^3буст^1 режим.

SHOW_KNIFEON = Нож теперь ^3видимый^1.
SHOW_KNIFEOFF = Нож теперь ^3не видимый^1.
AA_10 = ^3%n^1 установил ^3airaccelerate^1 на ^310^1.
AA_100 = ^3%n^1 установил ^3airaccelerate^1 на ^3100^1.

NOT_START_MIX = Пожалуйста, отключите другой режим перед запуском матча.
NOT_START_KNIFE = Пожалуйста, отключите другой режим перед запуском ножевого раунда.
Expand Down Expand Up @@ -264,7 +252,6 @@ SAME_TIMER = Время равное! ОВЕРТАЙМ! Начало доп.
TT_WIN = ТТ Выиграли игру! (^3%s^1 разрыв)
MR_WIN = %s Выиграли игру! (^3%s^1 разрыв)
DUEL_WIN = Игрок ^3%n^1 (^3TT^1) выиграл дуэль!
SHOW_TOP = Показать топ игроков (^3/top^1).

CAP_CHOOSE = ^3%n^1 выбирает капитанов...
CAP_FIRST = Первый капитан: ^3%n^1.
Expand All @@ -277,21 +264,16 @@ TEAM_FULL = Команды полны!
PLAYER_CHOOSE = Капитан ^3%n^1 выбрал ^3%n^1.
PLAYER_CHOOSE_PTS = Капитан ^3%n^1 выбрал ^3%n^1 (^3%d^1 [^3%s^1]).

TRAINING_NOTALIVE = Вы должны быть живы, чтобы использовать эту команду!
CP_NOTALIVE = Вы должны быть живы, чтобы использовать чекпоинты!
CP_SAVE = Чекпоинт сохранен!
CP_NOT = У вас нет чекпоинтов!
CP_NOTSTUCK = У вас должен быть еще чекпинт чтобы использовать эту команду!
DAMAGE_INFO = Вы получили ^3%i^1 урона.
NOCLIP_ON = Ноклип включен!
NOCLIP_OFF = Ноклип отключен!
DAMAGE_ON = Показать дамаг - включен!
DAMAGE_OFF = Показать дамаг - отключен!


HUD_TIMETOWIN = Последний раунд!^n ТТ Нужно %s чтобы победить!
HUD_CAPWIN = Капитан %n победил!
HUD_KF_WIN_TT = Команда ТТ победила в ножевом раунде!
HUD_KF_WIN_CT = Команда КТ победила в ножевом раунде!
HUD_START_WAIT = %s^nВ ожидании %d игроков.
HUD_START_LAST = ПОСЛЕДНИЕ СЕКУНДЫ ПЕРЕД СТАРТОМ.
HUD_GAMEOVER = Игра закончена.
HUD_WIN_CT = КТ Победили!^n ТТ не хватило %s что-бы победить! ^n(Больше, чем roundtime)
HUD_WIN_TT = ТТ Победили!^n КТ таймер меньше, чем у команды ТТ!
HUD_STARTMIX1 = Начало игры через 3 секунды!
HUD_STARTMIX2 = Игра началась!^nУдачи и веселой игры!
HUD_STARTKNIFE = Начался ножевой раунд за выбор команды!
Expand Down
2 changes: 1 addition & 1 deletion scripting/HnsMatchMaps.sma
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public cmdMapsMenuHandler(id, hMenu, item) {

if (hns_get_status() == MATCH_MAPPICK)
{
client_print_color(0, print_team_blue, "%s ^3%n^1 номинировал карту: ^3%s^1.", g_szPrefix, id, szMap);
client_print_color(0, print_team_blue, "%L", LANG_PLAYER, "MAPS_NOM", g_szPrefix, id, szMap);
}

menu_destroy(hMenu);
Expand Down
20 changes: 15 additions & 5 deletions scripting/HnsMatchPlayerInfo.sma
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,14 @@ public plugin_cfg() {
}

public cmdHUDInfo(id) {
g_HudOnOff[id] = !g_HudOnOff[id]
client_print_color(id, print_team_blue, "%s HUD info is now %sabled", g_szPrefix, g_HudOnOff[id] ? "^3En" : "^4Dis");
g_HudOnOff[id] = !g_HudOnOff[id];

if (g_HudOnOff[id]) {
client_print_color(id, print_team_blue, "%L", id, "HUD_ON", g_szPrefix);
} else {
client_print_color(id, print_team_blue, "%L", id, "HUD_OFF", g_szPrefix);
}

return PLUGIN_HANDLED;
}

Expand All @@ -69,7 +75,7 @@ public sayHandle(id) {
new Float:flGameTime = get_gametime();

if(g_flCmdNextUseTime[id] > flGameTime) {
client_print_color(id, print_team_blue, "%s Please wait ^3%.1f^1 seconds between commands!", g_szPrefix, g_flCmdNextUseTime[id] - flGameTime);
client_print_color(id, print_team_blue, "%L", id, "DMG_SPAM", g_szPrefix, g_flCmdNextUseTime[id] - flGameTime);
return PLUGIN_CONTINUE;
}

Expand All @@ -78,12 +84,16 @@ public sayHandle(id) {
new iTarget = pattern[0] ? cmd_target(id, pattern, CMDTARGET_ALLOW_SELF) : id;

if (!iTarget) {
client_print_color(id, print_team_blue, "%s There is no OR multiple players with matching pattern -> ^4%s", g_szPrefix, pattern);
client_print_color(id, print_team_blue, "%L", id, "DMG_ERR", g_szPrefix, pattern);
return PLUGIN_CONTINUE;
}

if (g_flDmg[iTarget]) {
client_print_color(0, print_team_blue, "%s ^3%n^1's fall damage ^3%.0f^1 HP - before ^3%.0f^1 - ^3%s^1 HP, ^3%.1f^1 seconds ago.", g_szPrefix, iTarget, g_flDmg[iTarget], g_flHealthBefore[iTarget], g_bDmgThisRound[iTarget] ? "^4Этот раунд" : "Не этот раунд", get_gametime() - g_flDmgTime[iTarget]);
if (g_bDmgThisRound[iTarget]) {
client_print_color(0, print_team_blue, "%L", LANG_PLAYER, "DMG_SHOW_ROUND", g_szPrefix, iTarget, g_flDmg[iTarget], g_flHealthBefore[iTarget], get_gametime() - g_flDmgTime[iTarget]);
} else {
client_print_color(0, print_team_blue, "%L", LANG_PLAYER, "DMG_SHOW", g_szPrefix, iTarget, g_flDmg[iTarget], g_flHealthBefore[iTarget], get_gametime() - g_flDmgTime[iTarget]);
}
}

return PLUGIN_CONTINUE;
Expand Down
4 changes: 2 additions & 2 deletions scripting/HnsMatchStats.sma
Original file line number Diff line number Diff line change
Expand Up @@ -75,12 +75,12 @@ public plugin_natives() {

public native_get_stats_stabs(amxx, params) {
enum { id = 1 };
return g_StatsRound[get_param(id)][PLR_STATS_STABS];
return iStats[get_param(id)][PLR_STATS_STABS];
}

public Float:native_get_stats_surv(amxx, params) {
enum { id = 1 };
return g_StatsRound[get_param(id)][PLR_STATS_SURVTIME];
return iStats[get_param(id)][PLR_STATS_SURVTIME];
}

public msgShowMenu(msgid, dest, id) {
Expand Down
2 changes: 1 addition & 1 deletion scripting/include/hns-match/addition/hnsmenu.inc
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ public menuSelectMode(id) {
}

if (g_iCurrentMode == MODE_MIX) {
chat_print(0, "This command is not available during the match!");
chat_print(id, "%L", id, "MODE_NOT_MIX");
return PLUGIN_HANDLED;
}

Expand Down
1 change: 0 additions & 1 deletion scripting/include/hns-match/addition/surrender.inc
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,6 @@ resetSurrenderData() {

autoLose(TeamName:iTeam) {
chat_print(0, "%L", LANG_PLAYER, "SUR_END", iTeam == TEAM_TERRORIST ? "TERRORISTS" : "CTS");
chat_print(0, "%L", LANG_PLAYER, "SHOW_TOP");

ExecuteForward(g_hForwards[MATCH_FINISH], _, iTeam == TEAM_TERRORIST ? 2 : 1);

Expand Down
6 changes: 5 additions & 1 deletion scripting/include/hns-match/modes/mode_knife.inl
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,11 @@ public kniferound_roundend(bool:win_ct) {
pickMenu(g_iCaptainPick);
}
case MATCH_TEAMKNIFE: {
setTaskHud(0, 2.0, 1, 255, 255, 255, 3.0, "Team %s Win", win_ct ? "CTS" : "Terrorists");
if (win_ct) {
setTaskHud(0, 2.0, 1, 255, 255, 255, 3.0, "%L", LANG_SERVER, "HUD_KF_WIN_CT");
} else {
setTaskHud(0, 2.0, 1, 255, 255, 255, 3.0, "%L", LANG_SERVER, "HUD_KF_WIN_TT");
}

savePlayers(win_ct ? TEAM_CT : TEAM_TERRORIST);
training_start();
Expand Down
4 changes: 2 additions & 2 deletions scripting/include/hns-match/modes/mode_manager.inl
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public wait_players() {
}

if (task_exists(TASK_STARTED)) {
setTaskHud(0, 0.0, 1, 255, 255, 255, 1.0, "LAST SECONDS BEFORE THE START.");
setTaskHud(0, 0.0, 1, 255, 255, 255, 1.0, "%L", LANG_SERVER, "HUD_START_LAST");
} else {
new iNum = get_num_players_in_match();

Expand All @@ -60,7 +60,7 @@ public wait_players() {

new sTime[24];
fnConvertTime(flWaitPlayersTime, sTime, charsmax(sTime));
setTaskHud(0, 0.0, 1, 255, 255, 255, 1.0, "%s^nWaiting for %d players.", sTime, ArraySize(g_aPlayersLoadData) - iNum);
setTaskHud(0, 0.0, 1, 255, 255, 255, 1.0, "%L", LANG_SERVER, "HUD_START_WAIT", sTime, ArraySize(g_aPlayersLoadData) - iNum);

if (flWaitPlayersTime <= 0.0) {
remove_task(TASK_WAIT);
Expand Down
Loading

0 comments on commit 3268cee

Please sign in to comment.