Перейти к содержимому
View in the app

A better way to browse. Learn more.

Zloplay community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

[Release] FDOadmin plugin for B3 (v1.04)

Опубликовано:

Ok, I had this laying around here for some time already, and both revision 108 of IW4M (onelog) and revision 22 of IW5M (exec command support) were good excuses to release it now :P

 

This is an admin plugin that focuses on adding IW4M and IW5M console commands to B3 in-game rcon.

At this stage, this plugin is deep in a beta stage (just added some commands as I felt like I needed them)

I'll be adding more commands in the future, and simplifying it's prefixes.

Note that I'm releasing here the full plugin, although some commands will only work on IW4M and some others on IW5M (stuff like fs_game for IW4M or loadscript for IW5M)

Anyway, you'll notice what are the available commands, just by looking at the xml code.

 

Changelog:

v1.04
Added "cmap". If your server admins don't know the fastfiles names for using with !map command, they can now use !cmap to use the map names instead.
Balanced the default permissions on the xml (you should still check and adjust that yourself)

v1.03
Added "maprotation/sv_maprotation"
Added "allowvote/g_allowvote"
Added "voice/sv_voice"
Added "deadchat/g_deadchat"

v1.02
Added "unscript/unloadscript". What goes in must come out, and scripts are no exception.
Added "balance/scr_teambalance"
Added "maxclients/sv_maxclients"

v1.01
Fixed a typo in scr_team_fftype command, where "shared" and "reflected" text prints were switched
Added "killstreaks/scr_game_hardpoints" command

 

 

So, what we need to do is:

 

Add this line on "b3.xml":

    

 

Now save this file as "b3\extplugins\conf\plugin_Fdoadmin.xml":


80
80
80
80
80
80
80
80
60
60
100
100
100
100
100
80
80
80
100
100
100
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80
80


 

Finally, save this file as "b3\extplugins\Fdoadmin.py":

#
# FourDeltaOne Admin Plugin for BigBrotherBot(B3) (www.bigbrotherbot.com)
#
# The purpose of this plugin is to expand b3 admin control
# over FourDeltaOne dedicated servers
#
# this plugin is based on Master_Jochen's "masteradmin" plugin

__version__ = '1.04'
__author__  = 'Paulofonta' #implying that I can actually code... lol

import b3, re, time
import b3.events

#-------------- done by xlr8or----------------------------------------------------------------------------
class FdoadminPlugin(b3.plugin.Plugin):
 _adminPlugin = None

 def startup(self):
   """\
   Initialize plugin settings
   """

   # get the admin plugin so we can register commands
   self._adminPlugin = self.console.getPlugin('admin')
   if not self._adminPlugin:
     # something is wrong, can't start without admin plugin
     self.error('Could not find admin plugin')
     return False

   # register our commands
   if 'commands' in self.config.sections():
     for cmd in self.config.options('commands'):
       level = self.config.get('commands', cmd)
       sp = cmd.split('-')
       alias = None
       if len(sp) == 2:
         cmd, alias = sp

       func = self.getCmd(cmd)
       if func:
         self._adminPlugin.registerCommand(self, cmd, level, func, alias)

   self.debug('Started')


 def getCmd(self, cmd):
   cmd = 'cmd_%s' % cmd
   if hasattr(self, cmd):
     func = getattr(self, cmd)
     return func

   return None


 def onEvent(self, event):
   """\
   Handle intercepted events
   """


# Commands implementation - done by Master_Jochen / expanded by Paulofonta


 def cmd_fastrestart(self, data, client, cmd=None):
   self.console.say('^2Fast restart upon admin request, ^1in 3')
   time.sleep(1)
   self.console.say('^1 2')
   time.sleep(1)
   self.console.say('^1 1')
   time.sleep(1)
   self.console.write('fast_restart')
   return True

 def cmd_maprestart(self, data, client, cmd=None):
   self.console.say('^2Map will restart upon admin request, ^1in 5')
   time.sleep(1)
   self.console.say('^1 4')
   time.sleep(1)
   self.console.say('^1 3')
   time.sleep(1)
   self.console.say('^1 2')
   time.sleep(1)
   self.console.say('^1 1')
   time.sleep(1)
   self.console.write('map_restart')
   return True

 def cmd_cmap(self, data, client, cmd=None):
   if not data:
     client.message('^7and the map is...?')
     return False
   else:
     input = data.split(' ',1)
  #IW4M-maps----------------------------------------------------------------------
     if input[0] == 'afghan' :
         self.console.say('^2Changing to map ^1Afghan^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_afghan')
         return True
     if input[0] == 'scrapyard' :
         self.console.say('^2Changing to map ^1Scrapyard^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_boneyard')
         return True
     if input[0] == 'wasteland' :
         self.console.say('^2Changing to map ^1Wasteland^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_brecourt')
         return True
     if input[0] == 'karachi' :
         self.console.say('^2Changing to map ^1Karachi^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_checkpoint')
         return True
     if input[0] == 'derail' :
         self.console.say('^2Changing to map ^1Derail^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_derail')
         return True
     if input[0] == 'estate' :
         self.console.say('^2Changing to map ^1Estate^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_estate')
         return True
     if input[0] == 'favela' :
         self.console.say('^2Changing to map ^1Favela^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_favela')
         return True
     if input[0] == 'highrise' :
         self.console.say('^2Changing to map ^1Highrise^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_highrise')
         return True
     if input[0] == 'invasion' :
         self.console.say('^2Changing to map ^1Invasion^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_invasion')
         return True
     if input[0] == 'skidrow' :
         self.console.say('^2Changing to map ^1Skidrow^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_nightshift')
         return True
     if input[0] == 'quarry' :
         self.console.say('^2Changing to map ^1Quarry^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_quarry')
         return True
     if input[0] == 'rundown' :
         self.console.say('^2Changing to map ^1Rundown^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_rundown')
         return True
     if input[0] == 'rust' :
         self.console.say('^2Changing to map ^1Rust^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_rust')
         return True
     if input[0] == 'subbase' :
         self.console.say('^2Changing to map ^1Sub Base^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_subbase')
         return True
     if input[0] == 'sub' :
         self.console.say('^2Changing to map ^1Sub Base^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_subbase')
         return True
     if input[0] == 'underpass' :
         self.console.say('^2Changing to map ^1Underpass^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_underpass')
         return True
	  #IW4M-DLC---------------------------------------------------------------------
     if input[0] == 'carnival' :
         self.console.say('^2Changing to map ^1Carnival^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_abandon')
         return True
     if input[0] == 'salvage' :
         self.console.say('^2Changing to map ^1Salvage^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_compact')
         return True
     if input[0] == 'bailout' :
         self.console.say('^2Changing to map ^1Bailout^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_complex')
         return True
     if input[0] == 'crash' :
         self.console.say('^2Changing to map ^1Crash^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_crash')
         return True
     if input[0] == 'fuel' :
         self.console.say('^2Changing to map ^1Fuel^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_fuel2')
         return True
     if input[0] == 'overgrown' :
         self.console.say('^2Changing to map ^1Overgrown^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_overgrown')
         return True
     if input[0] == 'storm' :
         self.console.say('^2Changing to map ^1Storm^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_storm')
         return True
     if input[0] == 'strike' :
         self.console.say('^2Changing to map ^1Strike^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_strike')
         return True
     if input[0] == 'trailerpark' :
         self.console.say('^2Changing to map ^1Trailer Park^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_trailerpark')
         return True
     if input[0] == 'trailer' :
         self.console.say('^2Changing to map ^1Trailer Park^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_trailerpark')
         return True
     if input[0] == 'vacant' :
         self.console.say('^2Changing to map ^1Vacant^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_vacant')
         return True
	  #Terminal-(IW4M-and-IW5M)-----------------------------------------------------
     if input[0] == 'terminal' :
         self.console.say('^2Changing to map ^1Terminal^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_terminal')
         self.console.write('map mp_terminal_cls')
         return True
	  #IW5M-maps--------------------------------------------------------------------
     if input[0] == 'lockdown' :
         self.console.say('^2Changing to map ^1Lockdown^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_alpha')
         return True
     if input[0] == 'bootleg' :
         self.console.say('^2Changing to map ^1Bootleg^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_bootleg')
         return True
     if input[0] == 'mission' :
         self.console.say('^2Changing to map ^1Mission^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_bravo')
         return True
     if input[0] == 'carbon' :
         self.console.say('^2Changing to map ^1Carbon^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_carbon')
         return True
     if input[0] == 'dome' :
         self.console.say('^2Changing to map ^1Dome^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_dome')
         return True
     if input[0] == 'downturn' :
         self.console.say('^2Changing to map ^1Downturn^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_exchange')
         return True
     if input[0] == 'hardhat' :
         self.console.say('^2Changing to map ^1Hardhat^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_hardhat')
         return True
     if input[0] == 'interchange' :
         self.console.say('^2Changing to map ^1Interchange^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_interchange')
         return True
     if input[0] == 'fallen' :
         self.console.say('^2Changing to map ^1Fallen^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_lambeth')
         return True
     if input[0] == 'bakaara' :
         self.console.say('^2Changing to map ^1Bakaara^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_mogadishu')
         return True
     if input[0] == 'resistance' :
         self.console.say('^2Changing to map ^1Resistance^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_paris')
         return True
     if input[0] == 'arkaden' :
         self.console.say('^2Changing to map ^1Arkaden^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_plaza2')
         return True
     if input[0] == 'outpost' :
         self.console.say('^2Changing to map ^1Outpost^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_radar')
         return True
     if input[0] == 'seatown' :
         self.console.say('^2Changing to map ^1Seatown^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_seatown')
         return True
     if input[0] == 'underground' :
         self.console.say('^2Changing to map ^1Underground^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_underground')
         return True
     if input[0] == 'village' :
         self.console.say('^2Changing to map ^1Village^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_village')
         return True
	  #IW5M-DLC--------------------------------------------------------------------
     if input[0] == 'aground' :
         self.console.say('^2Changing to map ^1Aground^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_aground_ss')
         return True
     if input[0] == 'boardwalk' :
         self.console.say('^2Changing to map ^1Boardwalk^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_boardwalk')
         return True
     if input[0] == 'u-turn' :
         self.console.say('^2Changing to map ^1U-Turn^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_burn_ss')
         return True
     if input[0] == 'uturn' :
         self.console.say('^2Changing to map ^1U-Turn^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_burn_ss')
         return True
     if input[0] == 'foundation' :
         self.console.say('^2Changing to map ^1Foundation^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_cement')
         return True
     if input[0] == 'erosion' :
         self.console.say('^2Changing to map ^1Erosion^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_courtyard_ss')
         return True
     if input[0] == 'intersection' :
         self.console.say('^2Changing to map ^1Intersection^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_crosswalk_ss')
         return True
     if input[0] == 'getaway' :
         self.console.say('^2Changing to map ^1Getaway^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_hillside_ss')
         return True
     if input[0] == 'piazza' :
         self.console.say('^2Changing to map ^1Piazza^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_italy')
         return True
     if input[0] == 'sanctuary' :
         self.console.say('^2Changing to map ^1Sanctuary^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_meteora')
         return True
     if input[0] == 'gulch' :
         self.console.say('^2Changing to map ^1Gulch^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_moab')
         return True
     if input[0] == 'blackbox' :
         self.console.say('^2Changing to map ^1Black Box^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_morningwood')
         return True
     if input[0] == 'black' :
         self.console.say('^2Changing to map ^1Black Box^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_morningwood')
         return True
     if input[0] == 'parish' :
         self.console.say('^2Changing to map ^1Parish^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_nola')
         return True
     if input[0] == 'overwatch' :
         self.console.say('^2Changing to map ^1Overwatch^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_overwatch')
         return True
     if input[0] == 'liberation' :
         self.console.say('^2Changing to map ^1Liberation^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_park')
         return True
     if input[0] == 'oasis' :
         self.console.say('^2Changing to map ^1Oasis^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_qadeem')
         return True
     if input[0] == 'lookout' :
         self.console.say('^2Changing to map ^1Lookout^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_restrepo_ss')
         return True
     if input[0] == 'offshore' :
         self.console.say('^2Changing to map ^1Off Shore^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_roughneck')
         return True
     if input[0] == 'off' :
         self.console.say('^2Changing to map ^1Off Shore^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_roughneck')
         return True
     if input[0] == 'decommission' :
         self.console.say('^2Changing to map ^1Decommission^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_shipbreaker')
         return True
     if input[0] == 'vortex' :
         self.console.say('^2Changing to map ^1Vortex^2, upon admin request, ^1in 3')
         time.sleep(1)
         self.console.say('^1 2')
         time.sleep(1)
         self.console.say('^1 1')
         time.sleep(1)
         self.console.write('map mp_six_ss')
         return True
     client.message('^7You have to use map names with this command (in lower cases)')   
   return True

 def cmd_hardcore(self, data, client, cmd=None):
   if not data:
     client.message('^7Missing data, type 0=off or 1=on after the command')
     return False
   else:
     input = data.split(' ',1)
     if input[0] == '1' :
         self.console.say('^2Hardcore ^1ON')
         self.console.write('g_hardcore 1')
         return True
     if input[0] == '0' :
         self.console.say('^2Hardcore ^1OFF')
         self.console.write('g_hardcore 0')
         return True
     client.message('^7Invalid data, type 1=on or 0=off')   
   return True

 def cmd_killstreaks(self, data, client, cmd=None):
   if not data:
     client.message('^7Missing data, type 0=off or 1=on after the command')
     return False
   else:
     input = data.split(' ',1)
     if input[0] == '1' :
         self.console.say('^2Killstreaks will now be ^1available')
         self.console.write('scr_game_hardpoints 1')
         return True
     if input[0] == '0' :
         self.console.say('^2Killstreaks will now be ^1UNavailable')
         self.console.write('scr_game_hardpoints 0')
         return True
     client.message('^7Invalid data, type 1=on or 0=off')   
   return True

 def cmd_ff(self, data, client, cmd=None):
   if not data:
     client.message('^7Missing data, type 0=off, 1=on, 2=reflected or 3=shared after the command')
     return False
   else:
     input = data.split(' ',1)
     if input[0] == '0' :
         self.console.say('^2Friendly Fire will now be ^1Off')
         time.sleep(1)
         self.console.write('scr_team_fftype 0')
         return True
     if input[0] == '1' :
         self.console.say('^2Friendly Fire will now be ^1On')
         time.sleep(1)
         self.console.write('scr_team_fftype 1')
         return True
     if input[0] == '2' :
         self.console.say('^2Friendly Fire will now be ^1Reflected')
         time.sleep(1)
         self.console.write('scr_team_fftype 2')
         return True
     if input[0] == '3' :
         self.console.say('^2Friendly Fire will now be ^1Shared')
         time.sleep(1)
         self.console.write('scr_team_fftype 3')
         return True
     client.message('^7Invalid data, type 0=off, 1=on, 2=reflected or 3=shared')   
   return True   

 def cmd_killcam(self, data, client, cmd=None):
   if not data:
     client.message('^7Missing data, type 0=off or 1=on after the command')
     return False
   else:
     input = data.split(' ',1)
     if input[0] == '1' :
         self.console.say('^2Killcam will now be ^1On')
         time.sleep(2)
         self.console.write('scr_game_allowkillcam 1')
         return True
     if input[0] == '0' :
         self.console.say('^2Killcam will now be ^1Off')
         time.sleep(2)
         self.console.write('scr_game_allowkillcam 0')
         return True
         client.message('^7Invalid data, type 0=off or 1=on')   
   return True

 def cmd_gametype(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a valid gametype after the command')
     return False
   else:
     self.console.say('^2Gametype will change to ^1 %s' % data)
     time.sleep(1)
     self.console.write('g_gametype %s' % data)
     return True         
   return True   

 def cmd_spectate(self, data, client, cmd=None):
   if not data:
     client.message('^7Missing data, type 0=Off, 1=Team, or 2=Free after the command')
     return False
   else:
     input = data.split(' ',1)
     if input[0] == '0' :
         self.console.say('^2Spectate type set to ^1Off')
         time.sleep(1)
         self.console.write('scr_game_spectatetype 0')
         return True
     if input[0] == '1' :
         self.console.say('^2Spectate type set to ^1Team')
         time.sleep(1)
         self.console.write('scr_game_spectatetype 1')
         return True
     if input[0] == '2' :
         self.console.say('^2Spectate type set to ^1Free')
         time.sleep(1)
         self.console.write('scr_game_spectatetype 2')
         return True
     client.message('^7Invalid data, type 0=off, 1=team or 2=free')   
   return True

 def cmd_balance(self, data, client, cmd=None):
   if not data:
     client.message('^7Missing data, type 0=off or 1=on after the command')
     return False
   else:
     input = data.split(' ',1)
     if input[0] == '1' :
         self.console.say('^2Team balancing will now be ^1On')
         time.sleep(2)
         self.console.write('scr_teambalance 1')
         return True
     if input[0] == '0' :
         self.console.say('^2Team balancing will now be ^1Off')
         time.sleep(2)
         self.console.write('scr_teambalance 0')
         return True
         client.message('^7Invalid data, type 0=off or 1=on')   
   return True

 def cmd_exec(self, data, client, cmd=None):
   self.console.say('^2Server config will be executed')
   time.sleep(1)
   self.console.write('exec %s' % data)
   return True

 def cmd_maprotation(self, data, client, cmd=None):
   self.console.say('^2Server playlist ^1%s^2 loaded' % data)
   time.sleep(1)
   self.console.write('sv_maprotation %s' % data)
   return True

 def cmd_password(self, data, client, cmd=None):
   self.console.say('^2Server password changed')
   self.console.write('g_password ""')
   time.sleep(1)
   self.console.write('g_password %s' % data)
   return True

 def cmd_hostname(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2Server name changed to to ^7 %s' % data)
     time.sleep(1)
     self.console.write('sv_hostname %s' % data)
     return True         
   return True   

 def cmd_maxclients(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2Server will support^1 %s ^2players after map load' % data)
     time.sleep(1)
     self.console.write('sv_maxclients %s' % data)
     return True         
   return True   

 def cmd_allowvote(self, data, client, cmd=None):
   if not data:
     client.message('^7Missing data, type 0=Disabled or 1=Available after the command')
     return False
   else:
     input = data.split(' ',1)
     if input[0] == '1' :
         self.console.say('^2Voting will now be ^1Available')
         time.sleep(2)
         self.console.write('g_allowvote 1')
         return True
     if input[0] == '0' :
         self.console.say('^2Voting will now be ^1Disabled')
         time.sleep(2)
         self.console.write('g_allowvote 0')
         return True
         client.message('^7Invalid data, type 0=Disabled or 1=Available')   
   return True

 def cmd_voice(self, data, client, cmd=None):
   if not data:
     client.message('^7Missing data, type 0=Off, 1=Free, or 2=Team after the command')
     return False
   else:
     input = data.split(' ',1)
     if input[0] == '0' :
         self.console.say('^2You have the right to remain ^1Silent')
         time.sleep(1)
         self.console.write('sv_voice 0')
         return True
     if input[0] == '1' :
         self.console.say('^2You can now voice chat with ^1Everyone')
         time.sleep(1)
         self.console.write('sv_voice 1')
         return True
     if input[0] == '2' :
         self.console.say('^2You can now voice chat with your ^1Team')
         time.sleep(1)
         self.console.write('sv_voice 2')
         return True
     client.message('^7Invalid data, type 0=Off, 1=Free or 2=Team')   
   return True

 def cmd_deadchat(self, data, client, cmd=None):
   if not data:
     client.message('^7Missing data, type 0=off or 1=on after the command')
     return False
   else:
     input = data.split(' ',1)
     if input[0] == '1' :
         self.console.say('^2Dead people ^1can now talk')
         time.sleep(2)
         self.console.write('g_deadchat 1')
         return True
     if input[0] == '0' :
         self.console.say('^2Dead people ^1dont talk')
         time.sleep(2)
         self.console.write('g_deadchat 0')
         return True
         client.message('^7Invalid data, type 0=off or 1=on')   
   return True

 def cmd_mod(self, data, client, cmd=None):
  self.console.say('^1 %s ^2loaded' % data)
  time.sleep(1)
  self.console.write('fs_game %s' % data)
  return True   

 def cmd_script(self, data, client, cmd=None):
  self.console.say('^1 %s ^2loaded' % data)
  time.sleep(1)
  self.console.write('loadscript %s' % data)
  return True   

 def cmd_unscript(self, data, client, cmd=None):
  self.console.say('^1 %s ^2UNloaded' % data)
  time.sleep(1)
  self.console.write('unloadscript %s' % data)
  return True   

 def cmd_maxhealth(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2MaxHealth set to ^1 %s' % data)
     time.sleep(1)
     self.console.write('scr_player_maxhealth %s' % data)
     return True         
   return True   

 def cmd_regentime(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2Health Regen Time set to ^1 %s' % data)
     time.sleep(1)
     self.console.write('scr_player_healthregentime %s' % data)
     return True         
   return True   

#------------------ gametype based commands ------------------------
# scorelimit

 def cmd_arenascorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_arena_scorelimit %s' % data)
     return True         
   return True   

 def cmd_ctfscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_ctf_scorelimit %s' % data)
     return True         
   return True   

 def cmd_confscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_conf_scorelimit %s' % data)
     return True         
   return True   

 def cmd_demscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_dd_scorelimit %s' % data)
     return True         
   return True   

 def cmd_ffascorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_dm_scorelimit %s' % data)
     return True         
   return True   

 def cmd_domscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_dom_scorelimit %s' % data)
     return True         
   return True   

 def cmd_grndscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_grnd_scorelimit %s' % data)
     return True         
   return True   

 def cmd_gtnwscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_gtnw_scorelimit %s' % data)
     return True         
   return True   

 def cmd_gunscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_gun_scorelimit %s' % data)
     return True         
   return True   

 def cmd_headscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_koth_scorelimit %s' % data)
     return True         
   return True   

 def cmd_juggscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_jugg_scorelimit %s' % data)
     return True         
   return True   

 def cmd_ofscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_oneflag_scorelimit %s' % data)
     return True         
   return True   

 def cmd_oicscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_oic_scorelimit %s' % data)
     return True         
   return True   

 def cmd_sabscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_sab_scorelimit %s' % data)
     return True         
   return True   

 def cmd_sdscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_sd_scorelimit %s' % data)
     return True         
   return True   

 def cmd_tdefscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_tdef_scorelimit %s' % data)
     return True         
   return True   

 def cmd_tdmscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_war_scorelimit %s' % data)
     return True         
   return True   

 def cmd_tjuggscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_tjugg_scorelimit %s' % data)
     return True         
   return True   

 def cmd_vipscorelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2ScoreLimit set to ^1 %s ^2points' % data)
     time.sleep(1)
     self.console.write('scr_vip_scorelimit %s' % data)
     return True         
   return True   

# timelimit

 def cmd_arenatimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_arena_timelimit %s' % data)
     return True         
   return True   

 def cmd_conftimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_conf_timelimit %s' % data)
     return True         
   return True   

 def cmd_ctftimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_ctf_timelimit %s' % data)
     return True         
   return True   

 def cmd_demtimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_dd_timelimit %s' % data)
     return True         
   return True   

 def cmd_ffatimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_dm_timelimit %s' % data)
     return True         
   return True   

 def cmd_domtimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_dom_timelimit %s' % data)
     return True         
   return True   

 def cmd_grndtimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_grnd_timelimit %s' % data)
     return True         
   return True   

 def cmd_gtnwtimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_gtnw_timelimit %s' % data)
     return True         
   return True   

 def cmd_guntimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_gun_timelimit %s' % data)
     return True         
   return True   

 def cmd_headtimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_koth_timelimit %s' % data)
     return True         
   return True   

 def cmd_inftimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_infect_timelimit %s' % data)
     return True         
   return True   

 def cmd_juggtimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_jugg_timelimit %s' % data)
     return True         
   return True   

 def cmd_oftimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_oneflag_timelimit %s' % data)
     return True         
   return True   

 def cmd_oictimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_oic_timelimit %s' % data)
     return True         
   return True   

 def cmd_sabtimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_sab_timelimit %s' % data)
     return True         
   return True   

 def cmd_sdtimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_sd_timelimit %s' % data)
     return True         
   return True   

 def cmd_tdeftimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_tdef_timelimit %s' % data)
     return True         
   return True   

 def cmd_tdmtimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_war_timelimit %s' % data)
     return True         
   return True   

 def cmd_tjuggtimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_tjugg_timelimit %s' % data)
     return True         
   return True   

 def cmd_viptimelimit(self, data, client, cmd=None):
   if not data:
     client.message('^7Specify a value after the command')
     return False
   else:
     self.console.say('^2TimeLimit set to ^1 %s ^2minutes' % data)
     time.sleep(1)
     self.console.write('scr_vip_timelimit %s' %data)
     return True         
   return True   

#------------------- end of gametype based commands ----------------

 

Note that this is an initial release and there might be some bugs, since most of the work was copy-paste, edit :P

Also note that this code isn't "nab-proof". If you type something like "!g_gametype tdm", it will tell you that "gametype will change to tdm", but it won't change anything, because the server only recognizes tdm gametype as "war". So, to change the gametype to tdm, you have to input "!gametype war".

I would thank you if you report any bug, or suggest any command to be added.

 

One last thing about using this plugin with IW5M servers:

You can use !gametype/!g_gametype command to change gametype, but that's not adviceable. You should use that command on IW4M, but not on IW5M.

While changing the gametype on IW5, you should also load a ruleset for that gametype, to avoid gametype config issues. On IW4M, you got separate commands for each gametype, like scr_sd_scorelimit, scr_war_scorelimit, etc. But on IW5, some commands meaning will depend on the gametype being loaded (for example, "gameOpt commonOption.scoreLimit" will be round limit on SD, while it's kill score limit on Team Deathmatch).

To do that, the best way is to have a playlist for each gametype (sd.dspl that loads sd.dsr, tdm.dspl that loads tdm.dsr, and so on). Then use !maprotation/!sv_maprotation command to load another playlist (and let the map rotate or do !maprotate for the new recipe ruleset to load).

Like I said above, you may experience some "undesired results" if you change gametype on IW5M, without loading a dsr for that gametype.

 

I've open a topic on IW4M section, to discuss IW4M specific stuff on this plugin -> http://fourdeltaone.net/viewtopic.php?f=17&t=17663

 

Finally, as the credits on the python file mention, credits go for xlr8or for starting all b3 coding, and Master_Jochen, since I started this plugin using his "masteradmin" plugin code as base.

Featured Replies

Опубликовано:

thanks for this but what are new features?

Опубликовано:
thanks for this but what are new features?

 

New commands such as these

 

60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60

Опубликовано:
thanks for this but what are new features?

 

New commands such as these

 

60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60

that does nothing i don't see commands (like !mod [name] to load a mod)

Опубликовано:
thanks for this but what are new features?

 

New commands such as these

 

60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60

that does nothing i don't see commands (like !mod [name] to load a mod)

There are allot of commands,Also if you tried them you would be able to figure them out by looking at the list above

Опубликовано:
thanks for this but what are new features?

 

New commands such as these

 

60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60
60

that does nothing i don't see commands (like !mod [name] to load a mod)

There are allot of commands,Also if you tried them you would be able to figure them out by looking at the list above

i try doing !Help command for a list of commands ;)

Опубликовано:
  • Автор
that does nothing i don't see commands (like !mod [name] to load a mod)

!mod command is actually there, but that's for IW4M

You can use either !mod or !fs_game to load a mod on IW4M

Use !script or !loadscript to load a script on IW5M

Note that to load a mod, changing or restarting map is required on IW4M. On IW5M, !fast_restart is enough to load a script though.

Also note that for loading a mod with b3 on IW4M, you have to use revision 108 "onelog" feature. Reffer to the IW4M topic about this plugin to know more about it.

 

p.s.: thanks everyone for the positive feedback :)

This is the first time that I try to mess with code and release something.

  • 2 weeks later...
Опубликовано:

Okay, i found the xml file, i configure everythink like you write it in your tutorial, The b3 already sends Messanges to the server, but if i to example write "!help commands" etc. it happend nothing.

 

I think it doesnВґt take my orders, so i look in the log files:

 

http://pastebin.com/9pW2WRaB

 

U see..it takes it.. maybe its because i have no adminrights, could you say me how i can give me some Adminrights? Or can you say me Whats the Problem?

 

Greez

Опубликовано:
  • Автор

121105 19:16:51 DEBUG   'SELECT * FROM groups WHERE `keyword` = "superadmin" LIMIT 1'
121105 19:16:51 DEBUG   "Storage: getClientsMatching {'&group_bits': 128}"
121105 19:16:51 DEBUG   'AdminPlugin: 0 superadmins found in database'
121105 19:16:51 VERBOSE 'AdminPlugin: No SuperAdmins found, enabling !iamgod'

Make sure that b3 is reading "games_mp.log" from "scripts" folder and then use the command "!iamgod" when you enter the server next time.

  • 2 weeks later...
Опубликовано:
  • Автор

If it's IW4M, do

!mod ""

If it's IW5M, do !unscript [dll name]

Example:

!unscript Sharpshooter.dll

 

Note that a map loading on IW4M or atleast a fast_restart on IW5M is needed for the mod/script to unload.

Опубликовано:

I typed !mod mods/""

but got disconnected from server and the following msg was displayed : "Invalid server value 'mods/' for 'fs_game"

 

 

I have an idea :

To put a blank iwd in mods folder and name it unload, so i can unload mod by typing !mod mods/unload

But im not sure that will this work.

 

If it will then pls provide a blank iwd.

Thank You for help :D

Опубликовано:
  • Автор

You don't need a blank iwd.

If you type !mod mods/unload, the server will create an empty folder called "unload" on mods folder. And it will load a mod wich doesn't contain IWDs (meaning that it won't load anything)

 

EDIT: the command now works like fs_game "" to unload a mod.

fs_game mods/"" no longer works (and let's say that the way to do it now should have always been the logical form, but people got used to write a path before the quotes)

So, using this plugin to unload a mod on IW4M, do !mod "" or !fs_game ""

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Гость
Ответить в тему...

Сейчас на странице 0

  • Нет пользователей, просматривающих эту страницу

Важная информация

Используя этот сайт, вы соглашаетесь Условия использования.

Account

Navigation

Поиск

Поиск

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.