Use new locale strings
This commit is contained in:
@@ -174,7 +174,7 @@ function createBusinessLocationCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -217,7 +217,7 @@ function deleteBusinessCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -241,7 +241,7 @@ function setBusinessNameCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -269,12 +269,12 @@ function setBusinessOwnerCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!newBusinessOwner) {
|
||||
messagePlayerError(client, "Player not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidPlayer"));
|
||||
return false;
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -302,12 +302,12 @@ function setBusinessJobCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getJobData(jobId)) {
|
||||
messagePlayerError(client, "Job not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidJob"));
|
||||
return false;
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -329,14 +329,14 @@ function setBusinessClanCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError("Business not found!");
|
||||
messagePlayerError(getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -358,7 +358,7 @@ function setBusinessRankCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError("Business not found!");
|
||||
messagePlayerError(getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -373,7 +373,7 @@ function setBusinessRankCommand(command, params, client) {
|
||||
let clanId = getClanIdFromDatabaseId(getBusinessData(businessId).ownerId);
|
||||
rankId = getClanRankFromParams(clanId, params);
|
||||
if(!getClanRankData(clanId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
getBusinessData(businessId).rank = getClanRankData(clanId, rankId).databaseId;
|
||||
@@ -406,21 +406,21 @@ function setBusinessRankCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError("Business not found!");
|
||||
messagePlayerError(getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
let clanRankId = getClanRankFromParams(clanId, params);
|
||||
|
||||
if(!getClanRankData(clanId, clanRankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -457,12 +457,12 @@ function setBusinessJobCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
if(!getJobData(jobId)) {
|
||||
messagePlayerError(client, "Job not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidJob"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -483,7 +483,7 @@ function setBusinessPublicCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -504,7 +504,7 @@ function lockUnlockBusinessCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -535,7 +535,7 @@ function lockUnlockBusinessCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -559,7 +559,7 @@ function setBusinessEntranceFeeCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -583,7 +583,7 @@ function getBusinessInfoCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -624,7 +624,7 @@ function getBusinessFloorItemsCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -641,7 +641,7 @@ function getBusinessStorageItemsCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -656,7 +656,7 @@ function setBusinessPickupCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -687,7 +687,7 @@ function setBusinessInteriorTypeCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -742,7 +742,7 @@ function setBusinessBlipCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -773,7 +773,7 @@ function giveDefaultItemsToBusinessCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -806,7 +806,7 @@ function setBusinessEntranceLabelToDealershipCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -823,7 +823,7 @@ function deleteBusinessFloorItemsCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -844,7 +844,7 @@ function deleteBusinessStorageItemsCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -871,7 +871,7 @@ function withdrawFromBusinessCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -907,7 +907,7 @@ function setBusinessBuyPriceCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -942,7 +942,7 @@ function depositIntoBusinessCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -995,7 +995,7 @@ function orderItemForBusinessCommand(command, params, client) {
|
||||
logToConsole(LOG_DEBUG, `[VRR.Business] ${getPlayerDisplayForConsole(client)} is ordering ${amount} ${splitParams.slice(0,-2).join(" ")} (${value})`);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1041,7 +1041,7 @@ function viewBusinessTillAmountCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1059,7 +1059,7 @@ function buyBusinessCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1093,7 +1093,7 @@ function moveBusinessEntranceCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1124,7 +1124,7 @@ function moveBusinessExitCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1618,7 +1618,7 @@ function buyFromBusinessCommand(command, params, client) {
|
||||
let splitParams = params.split(" ");
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1716,7 +1716,7 @@ function setBusinessItemSellPriceCommand(command, params, client) {
|
||||
let businessId = getBusinessFromParams(splitParams[2]) || getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1751,7 +1751,7 @@ function storeItemInBusinessStorageCommand(command, params, client) {
|
||||
let businessId = getBusinessFromParams(splitParams[2]) || getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1787,7 +1787,7 @@ function stockItemOnBusinessFloorCommand(command, params, client) {
|
||||
let businessId = getPlayerBusiness(client);
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, "Business not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidBusiness"));
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -163,7 +163,7 @@ function listClanRanksCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -207,7 +207,7 @@ function deleteClanCommand(command, params, client) {
|
||||
let clanId = getClanFromParams(params);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -233,12 +233,12 @@ function setClanOwnerCommand(command, params, client) {
|
||||
let targetClient = getPlayerFromParams(splitParams[1]);
|
||||
|
||||
if(!targetClient) {
|
||||
messagePlayerError(client, "Player not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidPlayer"));
|
||||
return false;
|
||||
}
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -265,7 +265,7 @@ function setClanTagCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -290,7 +290,7 @@ function setClanNameCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -315,7 +315,7 @@ function createClanRankCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -345,7 +345,7 @@ function deleteClanRankCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -353,7 +353,7 @@ function deleteClanRankCommand(command, params, client) {
|
||||
let tempRankName = getClanRankData(clanId, rankId);
|
||||
|
||||
if(!getClanRankData(clanId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -379,7 +379,7 @@ function setClanMemberTagCommand(command, params, client) {
|
||||
let targetClient = getPlayerFromParams(splitParams[0]);
|
||||
|
||||
if(!targetClient) {
|
||||
messagePlayerError(client, "Player not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidPlayer"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -425,7 +425,7 @@ function setClanRankTagCommand(command, params, client) {
|
||||
let newTag = splitParams[splitParams.length-1];
|
||||
|
||||
if(!getClanRankData(clanId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -456,7 +456,7 @@ function setClanRankLevelCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -464,7 +464,7 @@ function setClanRankLevelCommand(command, params, client) {
|
||||
let newLevel = splitParams[splitParams.length-1];
|
||||
|
||||
if(!getClanRankData(clanId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -504,7 +504,7 @@ function addClanMemberFlagCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -512,7 +512,7 @@ function addClanMemberFlagCommand(command, params, client) {
|
||||
let targetClient = getPlayerFromParams(splitParams[0]);
|
||||
|
||||
if(!targetClient) {
|
||||
messagePlayerError(client, "Player not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidPlayer"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -556,7 +556,7 @@ function removeClanMemberFlagCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -564,7 +564,7 @@ function removeClanMemberFlagCommand(command, params, client) {
|
||||
let targetClient = getPlayerFromParams(splitParams[0]);
|
||||
|
||||
if(!targetClient) {
|
||||
messagePlayerError(client, "Player not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidPlayer"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -608,7 +608,7 @@ function addClanRankFlagCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -616,7 +616,7 @@ function addClanRankFlagCommand(command, params, client) {
|
||||
let rankId = getClanRankFromParams(clanId, splitParams[0]);
|
||||
|
||||
if(!getClanRankData(clanId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -647,7 +647,7 @@ function removeClanRankFlagCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -655,7 +655,7 @@ function removeClanRankFlagCommand(command, params, client) {
|
||||
let rankId = getClanRankFromParams(clanId, splitParams[0]);
|
||||
|
||||
if(!getClanRankData(clanId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -686,7 +686,7 @@ function showClanRankFlagsCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -694,7 +694,7 @@ function showClanRankFlagsCommand(command, params, client) {
|
||||
let rankId = getClanRankFromParams(clanId, splitParams[0]);
|
||||
|
||||
if(!getClanRankData(clanId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -734,7 +734,7 @@ function setClanMemberTitleCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -742,7 +742,7 @@ function setClanMemberTitleCommand(command, params, client) {
|
||||
let targetClient = getPlayerFromParams(splitParams[0]);
|
||||
|
||||
if(!targetClient) {
|
||||
messagePlayerError(client, "Player not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidPlayer"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -781,7 +781,7 @@ function setClanRankTitleCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -789,7 +789,7 @@ function setClanRankTitleCommand(command, params, client) {
|
||||
let rankId = getClanRankFromParams(clanId, splitParams[0]);
|
||||
|
||||
if(!getClanRankData(clanId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -814,7 +814,7 @@ function setClanMemberRankCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -823,12 +823,12 @@ function setClanMemberRankCommand(command, params, client) {
|
||||
let rankId = getClanRankFromParams(clanId, splitParams[1]);
|
||||
|
||||
if(!targetClient) {
|
||||
messagePlayerError(client, "Player not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidPlayer"));
|
||||
return false;
|
||||
}
|
||||
|
||||
if(!getClanRankData(clanId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1189,7 +1189,7 @@ function showClanFlagListCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(client);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1197,7 +1197,7 @@ function showClanFlagListCommand(command, params, client) {
|
||||
let rankId = getClanRankFromParams(clanId, splitParams[0]);
|
||||
|
||||
if(!getClanRankData(clanId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -253,7 +253,7 @@ function setHouseClanCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(params);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -293,14 +293,14 @@ function setHouseClanCommand(command, params, client) {
|
||||
let clanId = getPlayerClan(params);
|
||||
|
||||
if(!getClanData(clanId)) {
|
||||
messagePlayerError(client, "Clan not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidClan"));
|
||||
return false;
|
||||
}
|
||||
|
||||
let clanRankId = getClanRankFromParams(clanId, params);
|
||||
|
||||
if(!getClanRankData(clanId, clanRankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -335,7 +335,7 @@ function setHousePickupCommand(command, params, client) {
|
||||
let houseId = getPlayerHouse(client);
|
||||
|
||||
if(!getHouseData(houseId)) {
|
||||
messagePlayerError(client, "House not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidHouse"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -380,7 +380,7 @@ function setHouseInteriorTypeCommand(command, params, client) {
|
||||
let houseId = getPlayerHouse(client);
|
||||
|
||||
if(!getHouseData(houseId)) {
|
||||
messagePlayerError(client, "House not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidHouse"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -439,7 +439,7 @@ function setHouseBlipCommand(command, params, client) {
|
||||
let houseId = getPlayerHouse(client);
|
||||
|
||||
if(!getHouseData(houseId)) {
|
||||
messagePlayerError(client, "House not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidHouse"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -990,7 +990,7 @@ function getHouseInfoCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getHouseData(houseId)) {
|
||||
messagePlayerError(client, "House not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidHouse"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1035,7 +1035,7 @@ function setHouseBuyPriceCommand(command, params, client) {
|
||||
let houseId = getPlayerHouse(client);
|
||||
|
||||
if(!getHouseData(houseId)) {
|
||||
messagePlayerError(client, "House not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidHouse"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1063,7 +1063,7 @@ function setHouseRentPriceCommand(command, params, client) {
|
||||
let houseId = getPlayerHouse(client);
|
||||
|
||||
if(!getHouseData(houseId)) {
|
||||
messagePlayerError(client, "House not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidHouse"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -1083,7 +1083,7 @@ function buyHouseCommand(command, params, client) {
|
||||
let houseId = getPlayerHouse(client);
|
||||
|
||||
if(!getHouseData(houseId)) {
|
||||
messagePlayerError(client, "House not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidHouse"));
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -191,18 +191,18 @@ function enterExitPropertyCommand(command, params, client) {
|
||||
if(isEntrance) {
|
||||
if(getDistance(closestProperty.entrancePosition, getPlayerPosition(client)) <= getGlobalConfig().enterPropertyDistance) {
|
||||
if(closestProperty.locked) {
|
||||
meActionToNearbyPlayers(client, `tries to open the ${(isBusiness) ? "business" : "house"} door but fails because it's locked`);
|
||||
meActionToNearbyPlayers(client, getLocaleString(client, "EnterExitPropertyDoorLocked", (isBusiness) ? getLocaleString(client, "Business") : getLocaleString(client, "House")));
|
||||
return false;
|
||||
}
|
||||
|
||||
if(!closestProperty.hasInterior) {
|
||||
messagePlayerAlert(client, `This ${(isBusiness) ? "business" : "house"} does not have an interior, but you can still use commands at the door icon.`);
|
||||
messagePlayerAlert(client, getLocaleString(client, "PropertyNoInterior", (isBusiness) ? getLocaleString(client, "Business") : getLocaleString(client, "House")));
|
||||
return false;
|
||||
}
|
||||
|
||||
clearPlayerStateToEnterExitProperty(client);
|
||||
getPlayerData(client).pedState = VRR_PEDSTATE_ENTERINGPROPERTY;
|
||||
meActionToNearbyPlayers(client, `opens the door and enters the ${(isBusiness) ? "business" : "house"}`);
|
||||
meActionToNearbyPlayers(client, getLocaleString(client, "EntersProperty", (isBusiness) ? getLocaleString(client, "Business") : getLocaleString(client, "House")));
|
||||
|
||||
if(isFadeCameraSupported()) {
|
||||
fadeCamera(client, false, 1.0);
|
||||
@@ -232,12 +232,12 @@ function enterExitPropertyCommand(command, params, client) {
|
||||
} else {
|
||||
if(getDistance(closestProperty.exitPosition, getPlayerPosition(client)) <= getGlobalConfig().exitPropertyDistance) {
|
||||
if(closestProperty.locked) {
|
||||
meActionToNearbyPlayers(client, `tries to open the ${(isBusiness) ? "business" : "house"} door but fails because it's locked`);
|
||||
meActionToNearbyPlayers(client, getLocaleString(client, "EnterExitPropertyDoorLocked", (isBusiness) ? getLocaleString(client, "Business") : getLocaleString(client, "House")));
|
||||
return false;
|
||||
}
|
||||
getPlayerData(client).pedState = VRR_PEDSTATE_EXITINGPROPERTY;
|
||||
clearPlayerStateToEnterExitProperty(client)
|
||||
meActionToNearbyPlayers(client, `opens the door and exits the ${(isBusiness) ? "business" : "house"}`);
|
||||
meActionToNearbyPlayers(client, getLocaleString(client, "ExitsProperty", (isBusiness) ? getLocaleString(client, "Business") : getLocaleString(client, "House")));
|
||||
|
||||
if(isFadeCameraSupported()) {
|
||||
fadeCamera(client, false, 1.0);
|
||||
@@ -276,7 +276,7 @@ function getPlayerInfoCommand(command, params, client) {
|
||||
targetClient = getPlayerFromParams(params);
|
||||
|
||||
if(!getPlayerData(targetClient)) {
|
||||
messagePlayerError(client, "Player not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidPlayer"));
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -394,6 +394,7 @@ function gpsCommand(command, params, client) {
|
||||
case "skin":
|
||||
case "skins":
|
||||
case "clothes":
|
||||
case "player":
|
||||
useType = VRR_ITEM_USETYPE_SKIN;
|
||||
break;
|
||||
|
||||
@@ -402,6 +403,7 @@ function gpsCommand(command, params, client) {
|
||||
case "weapon":
|
||||
case "weapons":
|
||||
case "wep":
|
||||
case "weps":
|
||||
useType = VRR_ITEM_USETYPE_WEAPON;
|
||||
break;
|
||||
|
||||
@@ -414,10 +416,23 @@ function gpsCommand(command, params, client) {
|
||||
useType = VRR_ITEM_USETYPE_DRINK;
|
||||
break;
|
||||
|
||||
case "alcohol":
|
||||
case "booze":
|
||||
case "bar":
|
||||
useType = VRR_ITEM_USETYPE_ALCOHOL;
|
||||
break;
|
||||
|
||||
case "repair":
|
||||
case "carrepair":
|
||||
case "vehrepair":
|
||||
case "spray":
|
||||
case "fix":
|
||||
useType = VRR_ITEM_USETYPE_VEHREPAIR;
|
||||
break;
|
||||
|
||||
case "vehiclecolour":
|
||||
case "vehcolour":
|
||||
case "carcolour":
|
||||
case "colour":
|
||||
useType = VRR_ITEM_USETYPE_VEHCOLOUR;
|
||||
break;
|
||||
@@ -432,12 +447,12 @@ function gpsCommand(command, params, client) {
|
||||
|
||||
let businessId = getClosestBusinessWithBuyableItemOfUseType(useType);
|
||||
if(!businessId) {
|
||||
messagePlayerError(client, `There is no business with that item available`);
|
||||
messagePlayerError(client, getLocaleString(client, "NoBusinessWithItemType"));
|
||||
return false;
|
||||
}
|
||||
|
||||
if(!getBusinessData(businessId)) {
|
||||
messagePlayerError(client, `There is no business with that item available`);
|
||||
messagePlayerError(client, getLocaleString(client, "NoBusinessWithItemType"));
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -544,7 +544,7 @@ function playerInteriorCommand(command, params, client) {
|
||||
let splitParams = params.split(" ");
|
||||
let targetClient = getPlayerFromParams(splitParams[0]);
|
||||
if(!targetClient) {
|
||||
messagePlayerError(client, "Player not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidPlayer"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -569,7 +569,7 @@ function playerVirtualWorldCommand(command, params, client) {
|
||||
let splitParams = params.split(" ");
|
||||
let targetClient = getPlayerFromParams(splitParams[0]);
|
||||
if(!targetClient) {
|
||||
messagePlayerError(client, "Player not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidPlayer"));
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -48,16 +48,16 @@ function playStreamingRadioCommand(command, params, client) {
|
||||
return false;
|
||||
}
|
||||
|
||||
let radioStationId = params;
|
||||
let radioStationId = getRadioStationFromParams(params);
|
||||
|
||||
if(radioStationId != 0 && typeof getServerData().radioStations[radioStationId-1] == "undefined") {
|
||||
messagePlayerError(client, "That radio station ID does not exist!");
|
||||
messagePlayerError(client, getLocaleString(client, "InvalidRadioStation"));
|
||||
return false;
|
||||
}
|
||||
|
||||
if(isPlayerInAnyVehicle(client)) {
|
||||
if(!getVehicleData(getPlayerVehicle(client))) {
|
||||
messagePlayerError(client, "This is a random traffic vehicle and commands can't be used for it.");
|
||||
messagePlayerError(client, getLocaleString(client, "RandomVehicleCommandsDisabled"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -77,7 +77,7 @@ function playStreamingRadioCommand(command, params, client) {
|
||||
|
||||
getVehicleData(getPlayerVehicle(client)).streamingRadioStation = radioStationId-1;
|
||||
getPlayerData(client).streamingRadioStation = radioStationId-1;
|
||||
meActionToNearbyPlayers(client, `changes their vehicle's radio station to ${getRadioStationData(radioStationId-1).name} (${getRadioStationData(radioStationId-1).genre})`);
|
||||
meActionToNearbyPlayers(client, getLocaleString(client, "ActionVehicleRadioStationChange", getRadioStationData(radioStationId-1).name, getRadioStationData(radioStationId-1).genre));
|
||||
|
||||
let clients = getClients();
|
||||
for(let i in clients) {
|
||||
@@ -103,7 +103,7 @@ function playStreamingRadioCommand(command, params, client) {
|
||||
} else {
|
||||
getHouseData(houseId).streamingRadioStation = radioStationId-1;
|
||||
getPlayerData(client).streamingRadioStation = radioStationId-1;
|
||||
meActionToNearbyPlayers(client, `changes their house radio station to ${getRadioStationData(radioStationId-1).name} (${getRadioStationData(radioStationId-1).genre})`);
|
||||
meActionToNearbyPlayers(client, getLocaleString(client, "ActionHouseRadioStationChange", getRadioStationData(radioStationId-1).name, getRadioStationData(radioStationId-1).genre));
|
||||
|
||||
let clients = getClients();
|
||||
for(let i in clients) {
|
||||
@@ -129,7 +129,7 @@ function playStreamingRadioCommand(command, params, client) {
|
||||
} else {
|
||||
getBusinessData(businessId).streamingRadioStation = radioStationId-1;
|
||||
getPlayerData(client).streamingRadioStation = radioStationId-1;
|
||||
meActionToNearbyPlayers(client, `changes the business radio station to ${getRadioStationData(radioStationId-1).name} (${getRadioStationData(radioStationId-1).genre})`);
|
||||
meActionToNearbyPlayers(client, getLocaleString(client, "ActionBusinessRadioStationChange", getRadioStationData(radioStationId-1).name, getRadioStationData(radioStationId-1).genre));
|
||||
|
||||
let clients = getClients();
|
||||
for(let i in clients) {
|
||||
@@ -140,7 +140,7 @@ function playStreamingRadioCommand(command, params, client) {
|
||||
}
|
||||
}
|
||||
} else {
|
||||
messagePlayerError(client, "You need to be in a vehicle, business, or house to set it's radio station!");
|
||||
messagePlayerError(client, getLocaleString(client, "RadioStationLocationInvalid"));
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -157,7 +157,7 @@ function setStreamingRadioVolumeCommand(command, params, client) {
|
||||
let volumeLevel = params;
|
||||
|
||||
if(isNaN(volumeLevel)) {
|
||||
messagePlayerError(client, "Volume level must a number");
|
||||
messagePlayerError(client, getLocaleString(client, "RadioVolumeNotNumber"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -165,16 +165,16 @@ function setStreamingRadioVolumeCommand(command, params, client) {
|
||||
getPlayerData(client).accountData.streamingRadioVolume = toInteger(volumeLevel);
|
||||
let volumeEmoji = '';
|
||||
if(volumeLevel >= 60) {
|
||||
volumeEmoji = '🔊 ';
|
||||
volumeEmoji = '🔊';
|
||||
} else if(volumeLevel >= 30 && volumeLevel < 60) {
|
||||
volumeEmoji = '🔉 ';
|
||||
volumeEmoji = '🔉';
|
||||
} else if(volumeLevel > 0 && volumeLevel < 30) {
|
||||
volumeEmoji = '🔈 ';
|
||||
volumeEmoji = '🔈';
|
||||
} else if(volumeLevel <= 0) {
|
||||
volumeEmoji = '🔇 ';
|
||||
volumeEmoji = '🔇';
|
||||
}
|
||||
|
||||
messagePlayerSuccess(client, `${volumeEmoji}You set your streaming radio volume to ${volumeLevel}%`);
|
||||
messagePlayerSuccess(client, getLocaleString(client, "RadioVolumeChanged", volumeEmoji, volumeLevel));
|
||||
}
|
||||
|
||||
// ===========================================================================
|
||||
@@ -193,7 +193,7 @@ function showRadioStationListCommand(command, params, client) {
|
||||
|
||||
let chunkedList = splitArrayIntoChunks(stationList, 4);
|
||||
|
||||
messagePlayerNormal(client, `{clanOrange}== {jobYellow}Radio Stations {clanOrange}===========================`);
|
||||
messagePlayerNormal(client, makeChatSectionHeader(getLocaleString(client, "HeaderRadioStationsList")));
|
||||
|
||||
for(let i in chunkedList) {
|
||||
messagePlayerInfo(client, chunkedList[i].join(", "));
|
||||
|
||||
@@ -260,7 +260,7 @@ function vehicleLockCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getVehicleData(vehicle)) {
|
||||
messagePlayerError(client, "This is a random traffic vehicle and commands can't be used for it.");
|
||||
messagePlayerError(client, getLocaleString(client, "RandomVehicleCommandsDisabled"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -297,7 +297,7 @@ function vehicleTrunkCommand(command, params, client) {
|
||||
}
|
||||
|
||||
if(!getVehicleData(vehicle)) {
|
||||
messagePlayerError(client, "This is a random traffic vehicle and commands can't be used for it.");
|
||||
messagePlayerError(client, getLocaleString(client, "RandomVehicleCommandsDisabled"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -324,7 +324,7 @@ function vehicleLightsCommand(command, params, client) {
|
||||
let vehicle = getPlayerVehicle(client);
|
||||
|
||||
if(!getVehicleData(vehicle)) {
|
||||
messagePlayerError(client, "This is a random traffic vehicle and commands can't be used for it.");
|
||||
messagePlayerError(client, getLocaleString(client, "RandomVehicleCommandsDisabled"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -410,7 +410,7 @@ function vehicleSirenCommand(command, params, client) {
|
||||
let vehicle = getPlayerVehicle(client);
|
||||
|
||||
if(!getVehicleData(vehicle)) {
|
||||
messagePlayerError(client, "This is a random traffic vehicle and commands can't be used for it.");
|
||||
messagePlayerError(client, getLocaleString(client, "RandomVehicleCommandsDisabled"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -448,7 +448,7 @@ function vehicleAdminColourCommand(command, params, client) {
|
||||
let vehicle = getPlayerVehicle(client);
|
||||
|
||||
if(!getVehicleData(vehicle)) {
|
||||
messagePlayerError(client, "This is a random traffic vehicle and commands can't be used for it.");
|
||||
messagePlayerError(client, getLocaleString(client, "RandomVehicleCommandsDisabled"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -491,7 +491,7 @@ function vehicleAdminRepairCommand(command, params, client) {
|
||||
let vehicle = getPlayerVehicle(client);
|
||||
|
||||
if(!getVehicleData(vehicle)) {
|
||||
messagePlayerError(client, "This is a random traffic vehicle and commands can't be used for it.");
|
||||
messagePlayerError(client, getLocaleString(client, "RandomVehicleCommandsDisabled"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -526,7 +526,7 @@ function vehicleAdminLiveryCommand(command, params, client) {
|
||||
let vehicle = getPlayerVehicle(client);
|
||||
|
||||
if(!getVehicleData(vehicle)) {
|
||||
messagePlayerError(client, "This is a random traffic vehicle and commands can't be used for it.");
|
||||
messagePlayerError(client, getLocaleString(client, "RandomVehicleCommandsDisabled"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -567,7 +567,7 @@ function buyVehicleCommand(command, params, client) {
|
||||
let vehicle = getPlayerVehicle(client);
|
||||
|
||||
if(!getVehicleData(vehicle)) {
|
||||
messagePlayerError(client, "This is a random traffic vehicle and commands can't be used for it.");
|
||||
messagePlayerError(client, getLocaleString(client, "RandomVehicleCommandsDisabled"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -602,7 +602,7 @@ function rentVehicleCommand(command, params, client) {
|
||||
let vehicle = getPlayerVehicle(client);
|
||||
|
||||
if(!getVehicleData(vehicle)) {
|
||||
messagePlayerError(client, "This is a random traffic vehicle and commands can't be used for it.");
|
||||
messagePlayerError(client, getLocaleString(client, "RandomVehicleCommandsDisabled"));
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -648,7 +648,7 @@ function rentVehicleCommand(command, params, client) {
|
||||
// ===========================================================================
|
||||
|
||||
function enterVehicleAsPassengerCommand(command, params, client) {
|
||||
triggerNetworkEvent("vrr.passenger", client);
|
||||
sendNetworkEventToPlayer("vrr.passenger", client);
|
||||
}
|
||||
|
||||
// ===========================================================================
|
||||
@@ -791,7 +791,7 @@ function setVehicleRankCommand(command, params, client) {
|
||||
if(getVehicleData(vehicle).ownerType == VRR_VEHOWNER_CLAN) {
|
||||
rankId = getClanRankFromParams(getVehicleData(vehicle).ownerId, params);
|
||||
if(!getClanRankData(getVehicleData(vehicle).ownerId, rankId)) {
|
||||
messagePlayerError(client, "Clan rank not found!");
|
||||
messagePlayerError(client, getLocaleString(client, "ClanRankInvalid"));
|
||||
return false;
|
||||
}
|
||||
getVehicleData(vehicle).rank = getClanRankData(getVehicleData(vehicle).ownerId, rankId).databaseId;
|
||||
|
||||
Reference in New Issue
Block a user