Cirkus Serveri Forum
    • CoD4xAdmin
    • Recent
    • Popular
    • Groups
    • Users
    • Register
    • Login

    Adding RotU-Revolution custom commands

    Scheduled Pinned Locked Moved
    Support
    3
    3
    267
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • A
      AlexC
      last edited by

      Hi

      I was searching the internet all morning to find the answer, no luck.
      So RotU-Rev has some commands which I want to use on the server, but not much documentation present to do so.
      I was using B3 before, there worked fine.
      Then I found addCommand to cod4x itself, but no idea how to implement in the server with julia enabled.
      I added these:

      addCommand rv "set cmd revive:$pow:80:$arg:clnum"
      addCommand freeze "set cmd freezeplayer:$pow:80:$arg:clnum"
      addCommand unfreeze "set cmd unfreezeplayer:$pow:80:$arg:clnum"
      addCommand saybold "set cmd saybold:$pow:80:$arg:clnum"
      

      But doesn't work sadly..

      Any ideas?

      NeHoN J 2 Replies Last reply Reply Quote 0
      • NeHoN
        NeHo Administrators @AlexC
        last edited by

        @alexc You can add custom commands, have not tested it yet but you can tell me if it works. On the admin page you have the "Plugin Julia Settings" section and a link Server Commands. On that page on the right side there is a form "Add new Server Command", you can set the required power for every new command

        I keep hitting the 'Escape' key - but I'm still here. ...

        1 Reply Last reply Reply Quote 0
        • J
          JFF-Vince @AlexC
          last edited by

          @alexc

          There is a little bit more to this than would be apparent... Here is how I handled

          if you want to check it out... 18.185.183.228:28960

          I have some custom code in this file which does some of what you are after: /serverfiles/mods/rotu-r-alpha/scripts/server/_admin.gsc

          I call the commands with $revive playername

          if you need more help I can work with you to show what we have done, we also have some nice changes to the rotu which we could share if helpful.

          Callback_ScriptCommand(command, arguments)
          {
          wait 0.05;

          if( !isSubStr( self.name, "[MyClan]" ) )
          	return;
          
          /*
          self iprintlnbold(self.name + " executed command: " + command + " with arguments: " + arguments);
          */
          
          
          switch( toLower( command ) )
          {
          
          	case "easy":
          	
          		if(!isDefined(level.dif_zomPlayerMax))
          			level.dif_zomPlayerMax = 25;
          			
          		level.dif_zomPlayerMax -= 5;
          		if(level.dif_zomPlayerMax<5)
          			level.dif_zomPlayerMax = 20;
          			
          		iprintln ("^3"+self.name+" Set Max Live Zombies To: ^2" + int(level.dif_zomPlayerMax)); 
          		break;
          
          	case "hard":
          
          		if(!isDefined(level.dif_zomPlayerMax))
          			level.dif_zomPlayerMax = 25;
          
          		level.dif_zomPlayerMax += 5;
          		if(level.dif_zomPlayerMax>50)
          			level.dif_zomPlayerMax = 50;
          			
          		iprintln ("^3"+self.name+" Set Max Live Zombies To: ^1" + int(level.dif_zomPlayerMax)); 
          		break;
          
          	case "gift":
          		
          		args = StrTok(arguments, " ");
          		WhichPlayer = scripts\server\_adminmenu::getPlayerByName(args[0]);
          		
          		if(isDefined(WhichPlayer) && isDefined(args[1])) {
          			
          			if (int(args[1]) < 5000)
          				args[1] = 5000;
          				
          			if (int(args[1]) > 25000)
          				args[1] = 25000;
          				
          			/* self scripts\players\_players::incUpgradePoints( -1 * int(args[1]) ); */
          			WhichPlayer scripts\players\_players::incUpgradePoints( int(args[1]) );
          
          			iprintln ("^3"+self.name+" gave ^7" + int(args[1]) + " to ^3" + WhichPlayer.name); 
          		
          		}
          		
          		break;
          	
          	case "revive":
          
          		WhichPlayer = scripts\server\_adminmenu::getPlayerByName(arguments);
          		if(!isDefined(WhichPlayer))
          		 return;
          		 
          		if(!WhichPlayer.isAlive && !WhichPlayer.isZombie && WhichPlayer.isActive)
          		{
          			WhichPlayer scripts\players\_players::revive();
          			iprintln("^3"+WhichPlayer.name + "^7 has been revived by an admin.");
          		}
          		else
          			iprintln("^3"+WhichPlayer.name + "^7 could ^1NOT^7 been revived by an admin.");
          		
          		break;
          		
          	case "kill_zombies":
          
          		killZombies(0);
          		break;
          	
          }
          

          }

          1 Reply Last reply Reply Quote 0
          • First post
            Last post

          0

          Online

          191

          Users

          268

          Topics

          1.2k

          Posts
          Powered & Designed by NeHo