From 9713ecaf63df6855f0756fff2a71ab7a794c2aa1 Mon Sep 17 00:00:00 2001 From: Vortrex <3858226+VortrexFTW@users.noreply.github.com> Date: Sun, 5 Mar 2023 20:48:16 -0600 Subject: [PATCH] A few new commands --- scripts/server/command.js | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/scripts/server/command.js b/scripts/server/command.js index ec453a58..ce265f22 100644 --- a/scripts/server/command.js +++ b/scripts/server/command.js @@ -237,7 +237,7 @@ function loadCommands() { new CommandData("scode", executeServerCodeCommand, "", getStaffFlagValue("Developer"), true, true, "Execute serverside code"), new CommandData("ccode", executeClientCodeCommand, "", getStaffFlagValue("Developer"), true, true, "Execute clientside code for a player"), new CommandData("gmx", restartGameModeCommand, "", getStaffFlagValue("Developer"), true, true, "Restart this gamemode"), - new CommandData("saveall", saveServerDataCommand, "", getStaffFlagValue("Developer"), true, true, "Immediately save all data to database"), + new CommandData("saveall", saveServerDataCommand, "", getStaffFlagValue("ManageHouses") | getStaffFlagValue("ManageBusinesses") | getStaffFlagValue("ManageJobs") | getStaffFlagValue("ManagePayPhones"), true, true, "Immediately save all data to database"), new CommandData("docmd", simulateCommandForPlayerCommand, " [params]", getStaffFlagValue("Developer"), true, true, "Force a player to use a command"), new CommandData("docmdall", simulateCommandForAllPlayersCommand, " [params]", getStaffFlagValue("Developer"), true, true, "Force all players to use a command"), new CommandData("addloglevel", addLogLevelCommand, "", getStaffFlagValue("Developer"), true, true, "Adds a log level"), @@ -248,7 +248,6 @@ function loadCommands() { new CommandData("streamurlall", streamAudioURLToAllPlayersCommand, " ", getStaffFlagValue("Developer"), true, true, "Plays a URL radio stream for all players"), new CommandData("streamnameall", streamAudioNameToAllPlayersCommand, " ", getStaffFlagValue("Developer"), true, true, "Plays an audio file stream for all players"), - new CommandData("forceresetpass", forceAccountPasswordResetCommand, "", getStaffFlagValue("Developer"), true, true), new CommandData("fixblips", fixAllServerBlipsCommand, "", getStaffFlagValue("Developer"), true, true, "Clears and recreates all map blips"), new CommandData("fixpickups", fixAllServerPickupsCommand, "", getStaffFlagValue("Developer"), true, true, "Clears and recreates all pickups"), new CommandData("resetambience", resetAllServerAmbienceElementsCommand, "", getStaffFlagValue("ManageWorld"), true, true, "Clears all current server ambience elements (traffic, peds, etc)"), @@ -382,7 +381,7 @@ function loadCommands() { new CommandData("quitjob", quitJobCommand, "", getStaffFlagValue("None"), true, false, "Leave your job and be unemployed"), new CommandData("uniform", jobUniformCommand, "[uniform]", getStaffFlagValue("None"), true, false, "Use a job uniform"), new CommandData("equip", jobEquipmentCommand, "[equipment]", getStaffFlagValue("None"), true, false, "Get equipment for your job"), - new CommandData("jobrank", setPlayerJobRankCommand, "", getStaffFlagValue("None"), true, true, "Sets a player's job rank"), + new CommandData("jobrank", setPlayerJobRankCommand, " ", getStaffFlagValue("None"), true, true, "Sets a player's job rank"), new CommandData("jobs", jobListCommand, "", getStaffFlagValue("None"), true, false, "Shows a list of all jobs"), new CommandData("joblist", jobListCommand, "", getStaffFlagValue("None"), true, false, "Shows a list of all jobs"), new CommandData("alljobs", jobListCommand, "", getStaffFlagValue("None"), true, false, "Shows a list of all jobs"), @@ -489,6 +488,7 @@ function loadCommands() { new CommandData("kill", suicideCommand, "", getStaffFlagValue("None"), true, false, "Kills yourself"), new CommandData("suicide", suicideCommand, "", getStaffFlagValue("None"), true, false, "Kills yourself"), new CommandData("scoreboard", scoreBoardCommand, "", getStaffFlagValue("None"), true, false, "Shows the scoreboard (key press only)"), + new CommandData("locate", locatePlayerCommand, "", getStaffFlagValue("None"), true, true, "Shows the distance and direction of another player"), ], npc: [ new CommandData("addnpc", createNPCCommand, "", getStaffFlagValue("ManageNPCs"), true, false, "Creates an NPC with the specified skin"), @@ -514,6 +514,8 @@ function loadCommands() { new CommandData("nearpayphones", getNearbyPayPhonesCommand, "[range]", getStaffFlagValue("None"), true, false, "Shows a list of all nearby phones within certain range"), new CommandData("payphoneinfo", getPayPhoneInfoCommand, "[number]", getStaffFlagValue("None"), true, false, "Shows info of nearest payphone (or of payphone with number)"), new CommandData("phoneinfo", getPayPhoneInfoCommand, "[number]", getStaffFlagValue("None"), true, false, "Shows info of nearest payphone (or of payphone with number)"), + new CommandData("resetpayphones", resetAllPayPhonesCommand, "", getStaffFlagValue("ManagePayPhones"), true, false, "Resets all payphone states"), + new CommandData("fixpayphones", resetAllPayPhonesCommand, "", getStaffFlagValue("ManagePayPhones"), true, false, "Resets all payphone states"), //new CommandData("callphone", callPhoneNumberCommand, "", getStaffFlagValue("None"), true, false, "Rings the payphone with number"), ], race: [ @@ -620,8 +622,9 @@ function loadCommands() { new CommandData("biz", getPlayerCurrentBusinessCommand, "", getStaffFlagValue("BasicModeration"), true, true, "Gets which business a player is at/in"), new CommandData("business", getPlayerCurrentBusinessCommand, "", getStaffFlagValue("BasicModeration"), true, true, "Gets which business a player is at/in"), new CommandData("house", getPlayerCurrentHouseCommand, "", getStaffFlagValue("BasicModeration"), true, true, "Gets which house a player is at/in"), - //new CommandData("clearchat", clearChatCommand, "", getStaffFlagValue("None"), true, true, "Clears the chat"), - new CommandData("locate", locatePlayerCommand, "", getStaffFlagValue("None"), true, true, "Shows the distance and direction of another player"), + new CommandData("clearchat", clearChatCommand, "", getStaffFlagValue("BasicModeration"), true, true, "Clears the chat"), + new CommandData("forceresetpass", forceAccountPasswordResetCommand, "", getStaffFlagValue("ManageServer"), true, true), + new CommandData("chattype", setServerDefaultChatTypeCommand, "", getStaffFlagValue("ManageServer"), true, true, "Sets the normal chat type for the server"), ], startup: [], subAccount: [