void() menu_show_error =
{
- drawstring('0 200 0', "ERROR - MENU IS VISIBLE BUT NO MENU WAS DEFINED!", '8 8 0', '1 0 0', 1, 0);
+ drawstring('0 200 0', _("ERROR - MENU IS VISIBLE BUT NO MENU WAS DEFINED!"), '8 8 0', '1 0 0', 1, 0);
};
// CSQC_Init : Called every time the CSQC code is initialized (essentially at map load)
__engine_check = checkextension("DP_SV_WRITEPICTURE");
if(!__engine_check)
{
- print("^3Your engine build is outdated\n^3This Server uses a newer QC VM. Please update!\n");
+ print(_("^3Your engine build is outdated\n^3This Server uses a newer QC VM. Please update!\n"));
localcmd("\ndisconnect\n");
return;
}
check_unacceptable_compiler_bugs();
#ifdef WATERMARK
- print("^4CSQC Build information: ", WATERMARK(), "\n");
+ print(sprintf(_("^4CSQC Build information: %s\n"), WATERMARK()));
#endif
float i;
default:
if(GetTeam(Team, false) == NULL)
{
- print("trying to switch to unsupported team ", ftos(Team), "\n");
+ print(sprintf(_("trying to switch to unsupported team %d\n"), Team));
Team = COLOR_SPECTATOR;
}
break;
default:
if(GetTeam(Team, false) == NULL)
{
- print("trying to switch to unsupported team ", ftos(Team), "\n");
+ print(sprintf(_("trying to switch to unsupported team %d\n"), Team));
Team = COLOR_SPECTATOR;
}
break;
{
if(o.has_team)
{
- //print("(DISCONNECT) leave team ", ftos(o.team), "\n");
tm = GetTeam(o.team, false);
tm.team_size -= 1;
o.has_team = 0;
{
if not(o.has_team)
{
- //print("(CONNECT) enter team ", ftos(o.team), "\n");
o.team = Team;
tm = GetTeam(Team, true);
tm.team_size += 1;
}
else if(Team != o.team)
{
- //print("(CHANGE) leave team ", ftos(o.team), "\n");
tm = GetTeam(o.team, false);
tm.team_size -= 1;
o.team = Team;
- //print("(CHANGE) enter team ", ftos(o.team), "\n");
tm = GetTeam(Team, true);
tm.team_size += 1;
return TRUE;
{
if(e.sort_prev)
{
- //print("playerchecker: KILL KILL KILL\n");
// player disconnected
SetTeam(e, -1);
RemovePlayer(e);
{
if not(e.sort_prev)
{
- //print("playerchecker: SPAWN SPAWN SPAWN\n");
// player connected
if not(e)
playerslots[i] = e = spawn();
void TrueAim_Init();
void PostInit(void)
{
- print(strcat("PostInit\n maxclients = ", ftos(maxclients), "\n"));
localcmd(strcat("\nscoreboard_columns_set ", autocvar_scoreboard_columns, ";\n"));
entity playerchecker;
return true;
} else if(strCmd == "hud_save") { // save hud config
if(argv(1) == "" || argv(2)) {
- print("Usage:\n");
- print("hud_save configname (saves to hud_skinname_configname.cfg)\n");
+ print(_("Usage:\n"));
+ print(_("hud_save configname (saves to hud_skinname_configname.cfg)\n"));
}
else
HUD_Panel_ExportCfg(argv(1));
if(argv(0) == "help" || argc == 0)
{
- print("Usage: cl_cmd COMMAND..., where possible commands are:\n");
- print(" settemp cvar value\n");
- print(" scoreboard_columns_set ...\n");
- print(" scoreboard_columns_help\n");
+ print(_("Usage: cl_cmd COMMAND..., where possible commands are:\n"));
+ print(_(" settemp cvar value\n"));
+ print(_(" scoreboard_columns_set ...\n"));
+ print(_(" scoreboard_columns_help\n"));
GameCommand_Generic("help");
return;
}
#ifdef DP_CSQC_ENTITY_REMOVE_IS_B0RKED
if(!isNew && n != self.sv_entnum)
{
- print("A CSQC entity changed its owner!\n");
+ print(_("A CSQC entity changed its owner!\n"));
isNew = true;
Ent_Remove();
self.enttype = ENT_CLIENT_SCORES;
if(self.enttype)
if(t != self.enttype)
{
- print("A CSQC entity changed its type!\n");
+ print(_("A CSQC entity changed its type!\n"));
Ent_Remove();
bIsNewEntity = 1;
}
case ENT_CLIENT_GAUNTLET: Ent_ReadHook(bIsNewEntity, ENT_CLIENT_GAUNTLET); break;
case ENT_CLIENT_ACCURACY: Ent_ReadAccuracy(); break;
default:
- error(strcat("unknown entity type in CSQC_Ent_Update: ", ftos(self.enttype), "\n"));
+ error(strcat(_("unknown entity type in CSQC_Ent_Update: %d\n"), self.enttype));
break;
}
if ("" == keys) {
if (hud_showbinds > 1)
- return strcat(text, " (not bound)");
+ return sprintf(_("%s (not bound)"), text);
else
return text;
}
else if (hud_showbinds > 1)
- return strcat(text, " (", keys, ")");
+ return sprintf(_("%s (%s)"), text, keys);
else
return keys;
}
color = getplayerkey(player_localentnum-1, "topcolor");
if(getstati(STAT_CTF_STATE) == CTF_STATE_COMMANDER) {
- drawstring(ps, "\x1D\x1E\x1E\x1E\x1E Order Menu \x1E\x1E\x1E\x1E\x1F", '8 8 0', '1 1 0', 1, 0); ps += po;
- drawstring(ps, strcat("Order: ", ctf_temp_1), '8 8 0', '1 1 0', 1, 0); ps += po;
- drawcolorcodedstring(ps, "1) ^3previous page", '8 8 0', 1, 0); ps += po;
- drawcolorcodedstring(ps, "2) ^3next page", '8 8 0', 1, 0); ps += po;
+ drawstring(ps, _("----- Order Menu -----"), '8 8 0', '1 1 0', 1, 0); ps += po;
+ drawstring(ps, sprintf(_("Order: %s"), ctf_temp_1), '8 8 0', '1 1 0', 1, 0); ps += po;
+ drawcolorcodedstring(ps, _("1) ^3previous page"), '8 8 0', 1, 0); ps += po;
+ drawcolorcodedstring(ps, _("2) ^3next page"), '8 8 0', 1, 0); ps += po;
for((n = 2), (p = i = 0); i < maxclients && n > 0; ++i) {
frags = getplayerkey(i, "frags");
if(!frags || (i+1) == player_localentnum)
drawcolorcodedstring(ps, strcat(ftos(n), ") ", GetPlayerName(i), " : ", ftos(getstatf(STAT_CTF_STATE))), '8 8 0', 1, 0); ps += po;
}
}
- drawstring(ps, "ESC) Exit Menu", '8 8 0', '1 1 0', 1, 0); ps += po;
+ drawstring(ps, _("ESC) Exit Menu"), '8 8 0', '1 1 0', 1, 0); ps += po;
} else {
menu_close();
}
}
}
if(n == 0) {
- //print(strcat("Issuing order to: ", ftos(i+1), "\n"));
+ //print(sprintf(_("Issuing order to: %d\n"), i+1));
//print(strcat("cmd order #", ftos(i+1), " ", ctf_temp_1, ";\n"));
localcmd(strcat("\ncmd order #", ftos(i+1), " ", ctf_temp_1, ";"));
} else {
- print(strcat("Couldn't find player ", ftos(chose), "\n"));
+ print(sprintf(_("Couldn't find player %d\n"), chose));
}
return TRUE;
} else if(nSecondary == K_ESCAPE) {
strunzone(ctf_temp_1);
menu_close();
} else {
- //print(strcat("Menu action ", arg, " does not exist.\n"));
+ //print(sprintf(_("Menu action %s does not exist.\n"), arg));
return FALSE;
}
return TRUE;
po = '0 8 0';
if(getstati(STAT_CTF_STATE) == CTF_STATE_COMMANDER) {
- drawstring(ps, "\x1D\x1E\x1E\x1E\x1E Command Menu \x1E\x1E\x1E\x1E\x1F", '8 8 0', '1 1 0', 1, 0); ps += po;
- drawstring(ps, "Issue orders:", '8 8 0', '1 1 0', 1, 0); ps += po;
- drawstring(ps, " 1) Attack ", '8 8 0', '1 1 0', 1, 0);
- drawstring(ps + '80 0 0', " \x0F", '8 8 0', '1 1 1', 1, 0); ps += po;
- drawstring(ps, " 2) Defend \x0E", '8 8 0', '1 1 0', 1, 0); ps += po;
+ drawstring(ps, _("----- Command Menu -----"), '8 8 0', '1 1 0', 1, 0); ps += po;
+ drawstring(ps, _("Issue orders:"), '8 8 0', '1 1 0', 1, 0); ps += po;
+ drawstring(ps, _(" 1) Attack "), '8 8 0', '1 1 0', 1, 0);
+ drawstring(ps + '80 0 0', _(" \x0F"), '8 8 0', '1 1 1', 1, 0); ps += po;
+ drawstring(ps, _(" 2) Defend \x0E"), '8 8 0', '1 1 0', 1, 0); ps += po;
ps += po;
- drawstring(ps, "3) Resign from command.", '8 8 0', '1 1 0', 1, 0); ps += po;
- drawstring(ps, "ESC) Exit Menu", '8 8 0', '1 1 0', 1, 0); ps += po;
+ drawstring(ps, _("3) Resign from command."), '8 8 0', '1 1 0', 1, 0); ps += po;
+ drawstring(ps, _("ESC) Exit Menu"), '8 8 0', '1 1 0', 1, 0); ps += po;
} else {
menu_close();
}
} else if(stat == CTF_STATE_DEFEND) {
drawpic('0 0 0', "gfx/ctf_ic_def.tga", '64 64 0', '1 1 1', 1, 0);
} else if(stat == CTF_STATE_COMMANDER) {
- drawstring('0 0 0', "You're commander!", '8 8 0', '1 1 1', 1, 0);
+ drawstring('0 0 0', _("You're commander!"), '8 8 0', '1 1 1', 1, 0);
} else if(stat < 0) {
} else {
- drawstring('0 0 0', "Awaiting orders...", '8 8 0', '1 1 1', 0.5, 0);
+ drawstring('0 0 0', _("Awaiting orders..."), '8 8 0', '1 1 1', 0.5, 0);
}
};
thisforce = forcemul * force;
}
- //print("check ", ftos(num_for_edict(self)), " ", self.classname, "\n");
- //print(ftos(self.damageforcescale), "\n");
- //print(vtos(thisforce), "\n");
if(self.damageforcescale)
if(vlen(thisforce))
{
self.move_velocity = self.move_velocity + self.damageforcescale * thisforce;
self.move_flags &~= FL_ONGROUND;
- //print("pushed ", ftos(num_for_edict(self)), " loose\n");
}
if(w_issilent)
dirnew = normalize(direction * (1 - drift) + randomvec() * drift);
pos = pos_l + dirnew * steplength;
te_lightning1(world,pos_l,pos);
- //b_make(pos_l, pos,"particles/lightning2",0.25,64);
if(random() < branchfactor)
cl_effetcs_lightningarc(pos, pos + (dirnew * length * 0.25),seglength,drifts,drifte,min(branchfactor + branchfactor_add,1),branchfactor_add);
pos_l = pos;
}
te_lightning1(world,pos_l,to);
- //b_make(pos_l, to,"particles/lightning2",0.25,64);
}
else
te_lightning1(world,from,to);
- //b_make(from, to,"particles/lightning2",0.25,64);
}
// direction is perpendicular to the view normal, and perpendicular to the axis
thickdir = normalize(cross(axis, vieworg - from));
-/*
- print("from ", vtos(from), "\n");
- print("to ", vtos(to), "\n");
- print("org ", vtos(view_origin), "\n");
- print("dir ", vtos(thickdir), "\n");
-*/
-
A = from - thickdir * (thickness / 2);
B = from + thickdir * (thickness / 2);
C = to + thickdir * (thickness / 2);
string MapVote_FormatMapItem(float id, string map, float count, float maxwidth, vector fontsize)
{
string pre, post;
- pre = strcat(ftos(id+1), ". ");
+ pre = sprintf("%d. ", id+1);
if(mv_detail)
{
if(count == 1)
- post = strcat(" (1 vote)");
+ post = _(" (1 vote)");
else
- post = strcat(" (", ftos(count), " votes)");
+ post = sprintf(_(" (%d votes)"), count);
}
else
post = "";
pos_y = pos_y + hud_fontsize_y;
- label = MapVote_FormatMapItem(id, "Don't care", count, tsize, hud_fontsize);
+ label = MapVote_FormatMapItem(id, _("Don't care"), count, tsize, hud_fontsize);
text_size = stringwidth(label, false, hud_fontsize);
pos_y = ymin;
pos_z = 0;
//pos_x = center - stringwidth("Vote for a map", false) * 0.5 * 24;
- pos_x = center - stringwidth("Vote for a map", false, '12 0 0');
+ pos_x = center - stringwidth(_("Vote for a map"), false, '12 0 0');
drawstring(pos, "Vote for a map", '24 24 0', '1 1 1', 1, DRAWFLAG_NORMAL);
pos_y += 26;
i = ceil(max(0, mv_timeout - time));
- map = strcat(ftos(i), " seconds left");
+ map = sprintf(_("%d seconds left"), i);
//pos_x = center - stringwidth(map, false) * 0.5 * 16;
pos_x = center - stringwidth(map, false, '8 0 0');
drawstring(pos, map, '16 16 0', '0 1 0', 1, DRAWFLAG_NORMAL);
if(argc != 2 || !mv_pk3list)
{
- print("mv_mapdownload: ^3You're not supposed to use this command on your own!\n");
+ print(_("mv_mapdownload: ^3You're not supposed to use this command on your own!\n"));
return;
}
break;
if(!pak || pak.sv_entnum != id) {
- print("^1Error:^7 Couldn't find pak index.\n");
+ print(_("^1Error:^7 Couldn't find pak index.\n"));
return;
}
- //print(strcat("^3Adding: ", ftos(id), " - ", pak.message, " - "));
-
if(PreviewExists(pak.message))
{
mv_preview[id] = true;
- //print("^2Found...\n");
return;
} else {
- print("Requesting preview...\n");
+ print(_("Requesting preview...\n"));
localcmd(strcat("\ncmd mv_getpic ", ftos(id), "\n"));
}
}
mv_preview[i] = false;
- //print(strcat("RECV: ", map, " in ", pk3, "\n"));
MapVote_CheckPic(map, pk3, i);
}
else
- translated campaigns
-client/casings.qc
-client/ctf.qc
-client/damage.qc
-client/effects.qc
-client/gibs.qc
-client/hook.qc
-client/hud.qc
-client/hud.qh
-client/laser.qc
-client/Main.qc
-client/main.qh
-client/mapvoting.qc
client/miscfunctions.qc
client/modeleffects.qc
client/movetypes.qc
client/View.qc
client/wall.qc
client/waypointsprites.qc
+client/hud.qc