Monthly Target: $400 Donations: $140
 35% 

[Any] Map History (Updated 24-11-2013 @ 1.1.1)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
RedSword
SourceMod Plugin Approver
Join Date: Mar 2006
Location: Quebec, Canada
Plugin ID:
3001
Plugin Version:
1.1.1
Plugin Category:
Server Management
Plugin Game:
Any
Plugin Dependencies:
    Servers with this Plugin:
    16 
    Plugin Description:
    Allow any user to see map history in a menu
    Old 06-09-2012 , 12:27   [Any] Map History (Updated 24-11-2013 @ 1.1.1)
    Reply With Quote #1

    Map History

    v. 1.1.1

    Features :
    • Allow any players to see the last X maps by typing !lastmaps. Click image for larger version

Name:	maphistorypanel.png
Views:	569
Size:	37.7 KB
ID:	104819

    Why I made this plugin :
    • I felt like it was needed on my community's server, where an admin can't see map history because that server uses MAP and is very slowly getting on Sourcemod.
    • Admins sometimes want to vote a certain map, but they don't know when it was last played (I know, it is built-in in Sourcemod in "nextmap" plugin; but read the other points; and this one is standalone).
    • Let normal players know what were the last maps, so you can tell them to use !lastmaps. This prevents further whinning about asking for a map that was just played.

    In short : plugin is standalone and everyone can see map history.

    Commands :
    • <sm_lastmap | say !lastmap> to show what was the last map and when it started.
    • <sm_lastmaps | say !lastmaps> to show what were the last maps and when they started.

    ConVars :
    Code:
    // Allow people to use 'lastmap' command to see the last map. 0=disable command, 1=enable command (default).
    // -
    // Default: "1.0"
    // Minimum: "0.000000"
    // Maximum: "1.000000"
    mh_allow_lastmap "1.0"
    
    // Allow people to use the menu to show last maps. 0=disable command, 1=enable command (default).
    // -
    // Default: "1.0"
    // Minimum: "0.000000"
    // Maximum: "1.000000"
    mh_allow_menu "1.0"
    
    // Minimum time in seconds between two menu requests for a player. Default 2.
    // -
    // Default: "2.0"
    // Minimum: "0.000000"
    mh_allow_menu_delaymin "2.0"
    
    // Allow people to use the menu to show last maps. 0=disable command, 1=enable command (default).
    // -
    // Default: "32.00"
    // Minimum: "0.000000"
    // Maximum: "32.000000"
    mh_allow_menu_mapnumbershown "32.00"
    
    // Restrict 'lastmap' to people with this flag. "" for everyone.
    // -
    // Default: ""
    mh_lastmap_flag ""
    
    // Restrict 'lastmap' to people with this override. "" for everyone.
    // -
    // Default: ""
    mh_lastmap_override ""
    
    // Restrict 'menu' to people with this flag. "" for everyone.
    // -
    // Default: ""
    mh_menu_flag ""
    
    // Restrict 'menu' to people with this override. "" for everyone.
    // -
    // Default: ""
    mh_menu_override ""
    
    // Show current map in '!lastmaps' ? 1=yes, 0=no (default) ; changing value requires map change
    // -
    // Default: "0.0"
    // Minimum: "0.000000"
    // Maximum: "1.000000"
    mh_showcurrentmap "0.0"
    Known bugs :
    • None at the moment, please report any.

    Notes :
    • Place phrases in translation folder.
    • You may want to redefine the number of maps kept in memory at line 16 and recompile. 32 by default.
    • This uses a Panel and not a menu that you cycle through. This means a 1-page-only menu. I suggest avoiding big number of maps kept in history.
    • Thanks to graczu for his Mapcycle plugin that showed how to use Panels.

    --------------

    Changelog :
    • 1.0.0 Initial release. (09-06-2012)
    • 1.1.0 (20-12-2012)
      • Added support for admin flag and override. See ConVars :
        • mh_lastmap_flag
        • mh_lastmap_override
        • mh_menu_flag
        • mh_menu_override
      • Plugin now creates its own config files (due to a lot of ConVar) with the other SM cfgs (/cfg/sourcemod/).
      • Added possibility to choose the number of maps dynamically we want via a ConVar. See mh_allow_menu_mapnumbershown.
      • Added anti-menu spam. See ConVar mh_allow_menu_delaymin.
      • Removed FCVAR_NOTIFY from non-version ConVars and removed FCVAR_REPLICATED from version ConVar.
    • 1.1.1 (24-11-2013)
      • Modified how the plugin works (+updated for approval) :
        • It now uses the internal Sourcemod map history,
        • This allows to show the load the plugin on the fly and access the map history.
      • New convar mh_showcurrentmap, allowing to show or not the current map when using sm_lastmaps. Default is 0 (not showing current map).
      • Menu is now loaded on map change, rather than when asked (tiny optimization)
    • Approved by Peace-Maker. (31-12-2014)

    Todo list :
    • None at the moment.
    Attached Files
    File Type: txt maphistory.phrases.txt (454 Bytes, 289 views)
    File Type: sp Get Plugin or Get Source (maphistory.sp - 284 views - 9.6 KB)
    __________________
    My plugins :
    Red Maze
    Afk Bomb
    RAWR (per player/rounds Awp Restrict.)
    Kill Assist
    Be Medic

    You can also Donate if you appreciate my work

    Last edited by RedSword; 02-25-2015 at 21:52. Reason: 107dl; Ready for review.
    RedSword is offline
    pillepallus
    Senior Member
    Join Date: Oct 2011
    Old 06-09-2012 , 16:04   Re: [Any] Map History
    Reply With Quote #2

    many thanks!!!! now i know how long i have to wait if map is recently played!!!! many many thanks!!!

    and it would be creat when mapchooser extended would implement a feature to read this out and after crash or restart some recently played maps are still blocked.

    Last edited by pillepallus; 06-09-2012 at 16:07.
    pillepallus is offline
    RedSword
    SourceMod Plugin Approver
    Join Date: Mar 2006
    Location: Quebec, Canada
    Old 06-09-2012 , 16:56   Re: [Any] Map History
    Reply With Quote #3

    Quote:
    Originally Posted by pillepallus View Post
    many thanks!!!! now i know how long i have to wait if map is recently played!!!! many many thanks!!!

    and it would be creat when mapchooser extended would implement a feature to read this out and after crash or restart some recently played maps are still blocked.
    Your reply is appreciated.

    About mapchooser extension, I really don't plan on adding that. Since you have the time when a map started, you can calculate yourself how long the map was played for. In the image shown in the first post I quickly switched map a bunch of time to demonstrate my plugin at work; but those aren't realistic time intervals lol :$.
    __________________
    My plugins :
    Red Maze
    Afk Bomb
    RAWR (per player/rounds Awp Restrict.)
    Kill Assist
    Be Medic

    You can also Donate if you appreciate my work

    Last edited by RedSword; 06-09-2012 at 16:58.
    RedSword is offline
    pillepallus
    Senior Member
    Join Date: Oct 2011
    Old 06-09-2012 , 18:30   Re: [Any] Map History
    Reply With Quote #4

    for guys like me is this plugin really great!!!! many thanks again!!!

    i just want to play some maps and so i can caluclate how long i need to wait. so i can join later anddon't need to camp in spec. u saved so much of my time!!!!! my home server where i'm playing is using map rotation of 15 now so this is soooooo important to have.

    ye integration in mapchooser isn't possible on ur side except u can write the data to disk or database (map and times). so mapchooser can grep the data. just an idea. i'm using mapchooser extended cause very good support and features. till now i saw only 1 other guy who requested this function. but i think its very useful to continue the map rotation depending recently played maps.
    pillepallus is offline
    timort
    Member
    Join Date: Jun 2009
    Location: France
    Old 07-24-2012 , 07:04   Re: [Any] Map History
    Reply With Quote #5

    Yep very nice ;)
    timort is offline
    shavit
    AlliedModders Donor
    Join Date: Dec 2011
    Location: Israel
    Old 07-24-2012 , 18:24   Re: [Any] Map History
    Reply With Quote #6

    How the heck the menu is blue? o.0
    __________________
    My Plugins
    Not taking private requests, too busy.
    shavit is offline
    minimoney1
    SourceMod Donor
    Join Date: Dec 2010
    Old 07-24-2012 , 18:45   Re: [Any] Map History
    Reply With Quote #7

    Quote:
    Originally Posted by shavit View Post
    How the heck the menu is blue? o.0
    Custom GUI?

    Last edited by minimoney1; 07-24-2012 at 18:45.
    minimoney1 is offline
    RedSword
    SourceMod Plugin Approver
    Join Date: Mar 2006
    Location: Quebec, Canada
    Old 07-24-2012 , 21:40   Re: [Any] Map History
    Reply With Quote #8

    There is no menu. Only a non-menu panel.
    __________________
    My plugins :
    Red Maze
    Afk Bomb
    RAWR (per player/rounds Awp Restrict.)
    Kill Assist
    Be Medic

    You can also Donate if you appreciate my work

    Last edited by RedSword; 07-24-2012 at 21:40.
    RedSword is offline
    thetwistedpanda
    Good Little Panda
    Join Date: Sep 2008
    Old 07-24-2012 , 21:45   Re: [Any] Map History
    Reply With Quote #9

    He's referring to your attached screenshot with blue font.
    __________________
    thetwistedpanda is offline
    RedSword
    SourceMod Plugin Approver
    Join Date: Mar 2006
    Location: Quebec, Canada
    Old 07-24-2012 , 22:14   Re: [Any] Map History
    Reply With Quote #10

    Quote:
    Originally Posted by thetwistedpanda View Post
    He's referring to your attached screenshot with blue font.
    I thought that was normal. Well, yes a custom GUI apparently.

    I did think it was the usual Panel behaviour (since a normal menu for me looks like this : )

    Thanks for correcting me.
    __________________
    My plugins :
    Red Maze
    Afk Bomb
    RAWR (per player/rounds Awp Restrict.)
    Kill Assist
    Be Medic

    You can also Donate if you appreciate my work

    Last edited by RedSword; 07-24-2012 at 22:15.
    RedSword is offline
    Reply


    Thread Tools
    Display Modes

    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is On
    HTML code is Off

    Forum Jump


    All times are GMT -4. The time now is 23:35.


    Powered by vBulletin®
    Copyright ©2000 - 2017, vBulletin Solutions, Inc.
    Theme made by Freecode