Raised This Month: $202 Target: $400
 50% 

[TF2Items] Randomizer (v1.591, 08/11/2013)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
FlaminSarge
Veteran Member
Join Date: Jul 2010
Plugin ID:
1975
Plugin Version:
1.591
Plugin Category:
Gameplay
Plugin Game:
Team Fortress 2
Plugin Dependencies:
Servers with this Plugin:
257 
Plugin Description:
A remake of the TF2 Randomizer plugin using asherkin's TF2Items extension
Old 09-25-2010 , 21:06   [TF2Items] Randomizer (v1.591, 08/11/2013)
Reply With Quote #1


(Image Credit: KelpPlankton)


Gamedata link: https://gist.github.com/FlaminSarge/...cd964848446fef


You will need the latest TF2Items: https://builds.limetech.io/?p=tf2items

This is [TF2] Randomizer (http://forums.alliedmods.net/showthread.php?t=98127) remade using asherkin's TF2Items extension.
When enabled, players are set as a random class with random weapons, which re-roll upon being killed.
This randomizer, however, is able to give all the weapons, not just the few ones that have unique weapon classnames.


CVARS - default values in parentheses
Spoiler

COMMANDS (Admin only)
Spoiler


COMMANDS (For everyone, not just admins)
  • tf2items_rnd_loadout - Displays your current items again, prints them to chat, and opens a menu showing the stats of any custom weapons you have.
  • sm_myloadout - same as tf2items_rnd_loadout
  • sm_myweps - same as tf2items_rnd_loadout, so tell your users to use /myweps or !myweps in chat.
Installation (SM1.5+)
1) Install TF2Items and TF2Attributes (links are elsewhere in this post, it might do some good to take the time to find them).
1b) Optionally install SteamTools (search for it!) to automatically change the game description (in the server browser) when Randomizer is enabled (as per the cvar).
2) Place tf2items_randomizer.smx in tf/addons/sourcemod/plugins/
3) Place tf2items.randomizer.txt from here in tf/addons/sourcemod/gamedata/
4) Place rndmodelcrashfix.vpk from rndmodelcrashfix.zip in tf/custom/ if your server is crashing due to UTIL_SetModel issues.
5) Restart the server if you want to be absolutely sure things load properly.

Download the .smx file rather than clicking 'Get Plugin'.
Compile requirements: tf2items.inc file from TF2Items' download package, as well as tf2attributes.inc from TF2Attributes. If you want the SteamTools Game Description feature, compile with steamtools.inc too.

Voting:
If you have the "Custom Votes" plugin installed on your server, you can use the tf2randomizer.vote.cfg with it (put in addons/sourcemod/configs/customvotes folder) to add a vote for it (chat trigger is /voterandomizer).

If you want visible weapons, and you have SDKHooks and Attachables installed, https://forums.alliedmods.net/showthread.php?p=1374048

Models for the Rebel's Curse and Khopesh Climber:
https://forums.alliedmods.net/showpost.php?p=1338489&postcount=2

Notes
Spoiler


Changelog
Spoiler

Known Bugs
*Ammo is set correctly when the weapon is given, but when players pick up ammo boxes, the ammo sets to what the class normally would get from the pack. Sorta-fixed, actually, for the most part, though you might see some strangeness occasionally.

*Not really a bug, but I left in a lot of the old randomizer code including the ammo fixes (they're commented out).

*Blutsauger health loss is not a glitch, it is it's normal nerf. It needs the -2 hp per second for balance. Get moving!

*Be wary of using plugins that force player class, such as Zombie Fortress. While this plugin defers class changes to other plugins, and should not crash, please let me know if it does.

Credits
Spoiler


Where can I try this out before I install it?
These servers are running with this mode enabled, though some may be modified versions.

...
This was my first public plugin. Things are bound to be turrible.
Attached Files
File Type: cfg tf2randomizer.vote.cfg (370 Bytes, 7821 views)
File Type: smx tf2items_randomizer.smx (96.5 KB, 8849 views)
File Type: sp Get Plugin or Get Source (tf2items_randomizer.sp - 2998 views - 333.2 KB)
File Type: zip rndmodelcrashfix.zip (2.2 KB, 80 views)
__________________
Bread EOTL GunMettle Invasion will break everything. Don't even ask.

All plugins: Randomizer/GiveWeapon, ModelManager, etc. (+SaxtonHale)
Don't ask me about SourceMod stuff on Steam; instead, post in a thread or send PM here. You will be fed to javalia otherwise.
Psyduck likes replays.

Last edited by FlaminSarge; 08-11-2017 at 08:05.
FlaminSarge is offline
ummja
Senior Member
Join Date: Sep 2010
Old 09-26-2010 , 19:40   Re: [TF2Items] Randomizer (v0.8, 09/25/2010)
Reply With Quote #2

Installed on my server just about 10 mins ago. Not working.

I have the items extension too, it's a no go.
ummja is offline
ummja
Senior Member
Join Date: Sep 2010
Old 09-26-2010 , 19:54   Re: [TF2Items] Randomizer (v0.8, 09/25/2010)
Reply With Quote #3

Nevermind sir, it works perfectly! I apologise for the confusion...

I'm sadly a complete dumb shit and copy everything but the .smx file.

Nice one mate.
ummja is offline
FlaminSarge
Veteran Member
Join Date: Jul 2010
Old 09-26-2010 , 21:21   Re: [TF2Items] Randomizer (v0.8, 09/25/2010)
Reply With Quote #4

Awesome. Also, feel free to request custom items to add, as I can code those in. If anybody can help, I can convert the hardcoded arrays of weapons into a keyvalues file that lets users include their own weapons and choose which they want.
FlaminSarge is offline
ummja
Senior Member
Join Date: Sep 2010
Old 09-26-2010 , 22:45   Re: [TF2Items] Randomizer (v0.8, 09/25/2010)
Reply With Quote #5

Only thing I can POSSIBLY ask of you is to add this to the admin menu (to call a vote for randomizer or not) because often I run a server without it on and if I can set a flag for my admins / donators to call a randomizer vote I will probably kiss the ground you walk upon.

But yeah bud, you did damn good.

EDIT: Sir, I don't think I can stress the importance to me if you could get that vote thing done built into the admin menu...

It'd be preferred if you could work it into the admin menu but a chat trigger would suffice too.

Once again, you did amazing with this mod, but if it is possible I BEG you to do this for me.

Last edited by ummja; 09-26-2010 at 22:58.
ummja is offline
FlaminSarge
Veteran Member
Join Date: Jul 2010
Old 09-27-2010 , 01:55   Re: [TF2Items] Randomizer (v0.8, 09/25/2010)
Reply With Quote #6

I'm not sure how to add vote options into the plugin itself (looking at Melee Only plugin to figure out) but you can use this: http://forums.alliedmods.net/showthread.php?p=633808
to set up a custom vote for Randomizer on or off. Here's what I came up with to put in the "configs/customvotes/tf2itemsrandomizer.vote.cfg" for that plugin (automatically goes into the voting commands section of admin menu):
Code:
"tf2items_randomizer"
{
    "title"         "Turn TF2Items Randomizer {!tf2items_rnd_enabled|onoff}?"
    "type"          "onoff"
    "admin"            "sm_vote"
    "cmd"           "tf2items_rnd_enabled #1"
    "params"
    {
        "1"         "onoff"
    }
}
I highly suggest you read the instructions for the plugin, as I came up with the above config in about two minutes and it might not be right.

EDIT: Also in 0.9 (still testing!) I improved some stuff, added a /tf2items_rnd_enable command to set the tf2items_rnd_enabled cvar to 1 (as well as ..._disable for 0).
If the tf2items_rnd_fix_spy cvar is at 2, you won't undisguise if you attack with sapper or the Disguise kit or Bonk! or Crit a cola or Sandvich or Dalokohs. Please remind me of anything else that doesn't attack to add to this "safe list".
I also tried fixing ubers, but I have not tested that yet, so that's why 0.9 is still in testing

Last edited by FlaminSarge; 09-27-2010 at 02:01.
FlaminSarge is offline
ummja
Senior Member
Join Date: Sep 2010
Old 09-27-2010 , 07:08   Re: [TF2Items] Randomizer (v0.8, 09/25/2010)
Reply With Quote #7

Okay sir, thanks very much.

Unfortunately, I'm off to work right now. I'll test v0.9 the second I get home.

In case you want to see how your mod runs I'll give you the server IP and you can join me.
ummja is offline
Regis
Member
Join Date: Sep 2009
Old 09-27-2010 , 14:16   Re: [TF2Items] Randomizer (v0.8, 09/25/2010)
Reply With Quote #8

Did you manage to bypass the invisible weapons?
Regis is offline
failhorse
Junior Member
Join Date: Mar 2010
Location: Chicago IL
Old 09-27-2010 , 15:17   Re: [TF2Items] Randomizer (v0.8, 09/25/2010)
Reply With Quote #9

I'm getting this error, otherwise no problems.
Code:
[SM] Unable to load plugin "tf2items_randomizer.smx": Native "TF2_AddCondition" was not found
Running sourcemod 1.3.2 and mm 1.9.0dev

Tried refreshing, and pure 0 based off search suggestions.
__________________
Co-Founder of the Critsandvich Network
failhorse is offline
Inflikted
SourceMod Donor
Join Date: Jan 2009
Old 09-27-2010 , 15:24   Re: [TF2Items] Randomizer (v0.8, 09/25/2010)
Reply With Quote #10

Quote:
Originally Posted by failhorse View Post
I'm getting this error, otherwise no problems.
Code:
[SM] Unable to load plugin "tf2items_randomizer.smx": Native "TF2_AddCondition" was not found
Running sourcemod 1.3.2 and mm 1.9.0dev

Tried refreshing, and pure 0 based off search suggestions.
update your sourcemod to the newest one should fix that.

Last edited by Inflikted; 09-27-2010 at 16:41.
Inflikted 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 15:45.


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