Raised This Month: $ Target: $400
 0% 

[TF2] Pick a Medic (v1.0.1, Nov. 15/12)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
waylaidwanderer
SourceMod Donor
Join Date: Aug 2012
Plugin ID:
3363
Plugin Version:
1.0.1
Plugin Category:
Gameplay
Plugin Game:
Team Fortress 2
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Forces a player to be a medic.
    Old 11-11-2012 , 01:33   [TF2] Pick a Medic (v1.0.1, Nov. 15/12)
    Reply With Quote #1

    I made this plugin by request.

    You can make a random person on the server a medic. Could be useful for PUGs and Scrims or things like that.

    Description:
    • Forces a random player to become a medic (does not prevent them from changing class to something else after that).
    Commands:
    • sm_pickmedic | Randomly chooses a player, and then forces them to become a medic. Can be also triggered by typing !pickmedic or /pickmedic into chat. | Default Flag: GENERIC | Override: sm_pickmedic
    Cvars:
    • sm_pickmedic_version | Plugin version. Do not edit.
    • sm_pickmedic_enabled | 0 = Disable plugin, 1 = Enable plugin | Default Value: 1
    Installation:
    • Place pickmedic.smx into your addons/sourcemod/plugins folder.
    Changelog:
    • Fixed a bug that caused the plugin to do nothing (v1.0.1, November 15th, 2012)
    • Created and uploaded plugin (v1.0.0, November 10th, 2012)

    This plugin currently targets both teams.
    Attached Files
    File Type: sp Get Plugin or Get Source (pickmedic.sp - 695 views - 2.2 KB)

    Last edited by waylaidwanderer; 09-22-2014 at 02:03.
    waylaidwanderer is offline
    RedSword
    SourceMod Plugin Approver
    Join Date: Mar 2006
    Location: Quebec, Canada
    Old 07-05-2013 , 21:21   Re: [TF2] Pick a Medic (v1.0.1, Nov. 15/12)
    Reply With Quote #2

    Hi,

    I'm approving this plugin as there is no major flaw.

    However, there are few points you might want to change :
    • You're using FCVAR_REPLICATED. This can generate errors in the clients's console.
    • Your check on 'numClients' is done twice. See lines 81+

    No real need to update your plugin for that; but if you're to update, it wouldn't be bad to includes those change.

    Also, in your plugin description you say "Forces a random player to medic." ; however, it only simply changes the class once. Player can still change after. I'd edit your first post if I were you (I believe it is a bit misleading currently).

    Red
    __________________
    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
    RedSword is offline
    Reply



    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 21:51.


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