AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [ANY] Resize Players - 1.5.1 - 2014/11/20 (https://forums.alliedmods.net/showthread.php?t=193255)

11530 08-17-2012 19:47

[ANY] Resize Players - 1.5.1 - 2014/11/20
 
1 Attachment(s)

[ANY] Resize Players
Version 1.5.1

http://i.imgur.com/gbrps.png


Description:
Allows players to change their size (or just their head)! Big Spy? Tiny Terrorist? The choice is yours!
See the bottom of this post to find which Source 2009 games are compatible.
Commands:
  • sm_resize [#userid|name] [scale] [time in seconds] | Allows an admin to target multiple players. | Default Flag: CHEATS (N)
  • sm_resizeme | Toggles ones size between normal and the default scale, or uses a menu if the necessary ConVar is set. | Default Flag: GENERIC (B)
  • sm_resizehead [#userid|name] [scale] [time in seconds] | Allows an admin to target multiple players' heads. | Default Flag: CHEATS (N)
  • sm_resizemyhead | Toggles ones head size between normal and the default head scale, or uses a menu if the necessary ConVar is set. | Default Flag: GENERIC (B)
  • sm_resizehands [#userid|name] [scale] [time in seconds] | Allows an admin to target multiple players' hands and weapons. | Default Flag: CHEATS (N)
  • sm_resizemyhands | Toggles ones hand size between normal and the default hand scale, or uses a menu if the necessary ConVar is set. | Default Flag: GENERIC (B)
  • sm_resizetorso [#userid|name] [scale] [time in seconds] | Allows an admin to target multiple players' torsos. | Default Flag: CHEATS (N)
  • sm_resizemytorso | Toggles ones torso size between normal and the default torso scale, or uses a menu if the necessary ConVar is set. | Default Flag: GENERIC (B)
  • sm_resizereset [#userid|name] | Resets all targets' sizes to 1.0. | Default Flag: CHEATS (N)
  • sm_resizeresetme | Resets your own size to 1.0 | Default Flag: GENERIC (B)

ConVars:
  • sm_resize_version | Plugin version. Do not edit.
  • sm_resize_enabled | 0 = Disable plugin, 1 = Enable plugin | Default Value: 1
  • sm_resize_defaultresize | Default scale of players when resized. Any decimal value above 0 is valid. | Default Value: 0.4
  • sm_resize_defaultheadresize | Default scale of players' heads when resized. | Default Value: 2.5
  • sm_resize_defaulthandsresize | Default scale of players' hands when resized. | Default Value: 2.5
  • sm_resize_defaulttorsoresize | Default scale of players' torsos when resized. | Default Value: 2.5
  • sm_resize_menu | 0 = Disable menus, 1 = Enable menus when no command parameters are given, 2 = Enable for self-commands only. | Default Value: 0
  • sm_resize_voices | 0 = Normal voices, 1 = Voice pitch scales with size, 2 = No low-pitched voices, 3 = No high-pitched voices. | Default Value: 0
  • sm_resize_damage | 0 = Normal damage, 1 = Damage given scales with size, 2 = No up-scaled damage, 3 = No down-scaled damage. | SDKHooks | Default Value: 0
  • sm_resize_notify | 0 = No notifications, 1 = Respect sm_show_activity, 2 = Notify everyone. | Default Value: 1
  • sm_resize_bounds | Lower (optional) and upper bounds for resizing, separated with a comma. | Default Value: "0.1, 3.0"
  • sm_resize_headbounds | Lower (optional) and upper bounds for head resizing, separated with a comma. | Default Value: "0.25, 3.0"
  • sm_resize_handsbounds | Lower (optional) and upper bounds for hands resizing, separated with a comma. | Default Value: "0.25, 3.0"
  • sm_resize_torsobounds | Lower (optional) and upper bounds for torso resizing, separated with a comma. | Default Value: "0.25, 3.0"
  • sm_resize_menuitems | Resize menu's items (see Q&A). | Default Value: "0.1, Smallest; 0.25, Smaller; 0.50, Small; 1.00, Normal; 1.25, Large; 1.50, Larger; 2.00, Largest"
  • sm_resize_headmenuitems | Head resize menu's items (see Q&A). | Default Value: "0.50, Smallest; 0.75, Small; 1.00, Normal; 2.00, Large; 3.00, Largest"
  • sm_resize_handsmenuitems | Hand resize menu's items (see Q&A). | Default Value: "0.50, Smallest; 0.75, Small; 1.00, Normal; 2.00, Large; 3.00, Largest"
  • sm_resize_torsomenuitems | Torso resize menu's items (see Q&A). | Default Value: "0.50, Smallest; 0.75, Small; 1.00, Normal; 2.00, Large; 3.00, Largest"
  • sm_resize_logging | 0 = No logging, 1 = Log self/target resizes, 2 = Log target resizes only. | Default Value: 1
  • sm_resize_unstick | Revert when stuck: 0 = Never, 1 = Self-resizes only, 2 = Respawns only, 3 = Self-resizes and respawns. | Default Value: 1
  • sm_resize_backstab | 0 = Normal backstabs, 1 = Backstab damage scales proportionally with size. | TF2 | SDKHooks | Default Value: 0
  • sm_resize_cooldown | Cooldown duration for those without permission to bypass (in seconds). | Default Value: 0
  • sm_resize_onjoin | Add values to alter size upon joining, 0 = Disable, 1 = Admin only, 2 = Resize body, 4 = Resize head, 8 = Resize torso, 16 = Resize hands. | Default Value: 0
  • sm_resize_steps | 0 = Normal step-size, 1 = Step-size scales with size, 2 = No up-scaled steps, 3 = No down-scaled steps. | Default Value: 0

Overrides:
  • sm_resize | Access to sm_resize command. | Default Flag: CHEATS (N)
  • sm_resizeme | Access to sm_resizeme command. | Default Flag: GENERIC (B)
  • sm_resizehead | Access to sm_resizehead command. | Default Flag: CHEATS (N)
  • sm_resizemyhead | Access to sm_resizemyhead command. | Default Flag: GENERIC (B)
  • sm_resizehands | Access to sm_resizehands command. | Default Flag: CHEATS (N)
  • sm_resizemyhands | Access to sm_resizemyhands command. | Default Flag: GENERIC (B)
  • sm_resizetorso | Access to sm_resizetorso command. | Default Flag: CHEATS (N)
  • sm_resizemytorso | Access to sm_resizemytorso command. | Default Flag: GENERIC (B)
  • sm_resizereset | Access to sm_resizereset command. | Default Flag: CHEATS (N)
  • sm_resizeresetme | Access to sm_resizeresetme command. | Default Flag: GENERIC (B)
  • sm_resizejoinoverride | Only clients with this flag are resized when sm_resize_onjoin is set to admin only. | Default Flag: CHEATS (N)
  • sm_resizeheadjoinoverride | Only clients with this flag have their head resized when sm_resize_onjoin is set to admin only. | Default Flag: CHEATS (N)
  • sm_resizehandsjoinoverride | Only clients with this flag have their hands resized when sm_resize_onjoin is set to admin only. | Default Flag: CHEATS (N)
  • sm_resizetorsojoinoverride | Only clients with this flag have their torso resized when sm_resize_onjoin is set to admin only. | Default Flag: CHEATS (N)
  • sm_resizecooldownbypass | Clients with this flag bypass any command cooldown. | Default Flag: GENERIC (B)
  • sm_resizeboundsoverride | Clients with this flag are not restricted by the bounds set by sm_resize_bounds | Default Flag: ROOT (Z)
  • sm_resizeheadboundsoverride | Clients with this flag are not restricted by the bounds set by sm_resize_headbounds | Default Flag: ROOT (Z)
  • sm_resizehandsboundsoverride | Clients with this flag are not restricted by the bounds set by sm_resize_handsbounds | Default Flag: ROOT (Z)
  • sm_resizetorsoboundsoverride | Clients with this flag are not restricted by the bounds set by sm_resize_torsobounds | Default Flag: ROOT (Z)

Q&A:
  • How do I set bounds for my sm_resize(me) and sm_resize(my)head/hands/torso commands?
  • Set bounds with the sm_resize_bounds and sm_resize_headbounds ConVars, separating the minimum and maximum values with a comma. If you don't supply a minimum bound (or it is less than zero) then 0.0 will be used. Example: "0.5, 2.0".
  • How do I enable bounds for some admins but disable them for higher ones?
  • Use override flags sm_resizeboundsoverride and/or sm_resizeheadboundsoverride for the admins you want to be able to bypass restrictions.
  • How do I write my own custom menus?
  • Design your menus using the menu ConVars (see above). Each item in the menu is separated with a semicolon. Example: "0.5; 2.0" Each item can also have an optional label by putting it after the number and separated with a comma. Example: "0.5, Something; 2.0, SomethingElse".
  • How does the TF2 backstab damage work?
  • If the sm_resize_backstab ConVar is set to 1 then the spy will deal damage in proportion to his size. If a spy is at 50% size then he will deal 50% of the victim's maximum health (or more if overhealed). If he is at 25% size then he will deal 25% of the victim's maximum health, and so on. Maximum health altering items such as the Dalokohs Bar are taken into account automatically.

Installation:
Place ResizePlayers.smx into your addons/sourcemod/plugins folder.
Don't forget to subscribe to this thread for all the latest updates!
Changelog:
Spoiler


SDKHooks (already packed with SM 1.5.0+) is required if you want to scale damage.
This should work in other Source 2009 games, but is not completely tested (sm_resize(me) command confirmed working on CS:S, TF2, TF2 Beta and Garry's Mod and sm_resize(my)head/torso/hands is for TF2 only).

Many thanks to Sreaper who requested this in the first place!

Downloads prior to update: 14438 (2890)

Sreaper 08-17-2012 19:50

Re: [TF2] Resize Player
 
It's a great feeling to know there are many selfless programmers on this forum such as yourself, who are willing to take time out of their busy lives to help out the community! Thanks so much! :)

Jim E. Rustler 08-17-2012 19:52

Re: [TF2] Resize Player
 
Quote:

Originally Posted by Sreaper (Post 1774611)
It's a great feeling to know there are selfless programmers on this forum who are willing to take time out of their busy lives just to help out the community! Thanks so much! :)

Uh oh, I can feel a shitstorm a brewin' with that comment.

I'll grab my popcorn.

FoxMulder 08-17-2012 20:05

Re: [TF2] Resize Player
 
Nice! Are there any limits to the scale?

Sreaper 08-17-2012 20:08

Re: [TF2] Resize Player
 
Quote:

Originally Posted by FoxMulder (Post 1774627)
Nice! Are there any limits to the scale?

There is no limits to the scale but negative values are blocked due to client crashing, but decimal values such as 0.000000001 are fine.

This plugin has amazing functionality, you can rescale your player, and fit through areas normally not possible since the collision boxes get changed.

Jim E. Rustler 08-17-2012 20:19

Re: [TF2] Resize Player
 
Can you scale the player up? I've tried 1.5 but it still only makes me small.

Sreaper 08-17-2012 20:24

Re: [TF2] Resize Player
 
Quote:

Originally Posted by Jim E. Rustler (Post 1774644)
Can you scale the player up? I've tried 1.5 but it still only makes me small.

Do you still have that problem when when using 2 as a value?

Jim E. Rustler 08-17-2012 20:38

Re: [TF2] Resize Player
 
Quote:

Originally Posted by Sreaper (Post 1774650)
Do you still have that problem when when using 2 as a value?

Yup, not sure if you have to map change after changing the cvar via sm_cvar. At any rate, can't make anyone bigger than default. Oh well. I guess being small is just as good.

SmackDaddy 08-17-2012 21:02

Re: [TF2] Resize Player
 
Would like to see a video or screenshot of this......also, do the hitboxes stay the same or change with the size?

FoxMulder 08-17-2012 21:09

Re: [TF2] Resize Player
 
I added a few values in a menu rather than letting players pick any size.


http://i.imgur.com/F2kzol.jpg
Scale: 0.9

http://i.imgur.com/oY9Rnl.jpg
Scale: 0.8


http://i.imgur.com/IJ2bZl.jpg
Scale: 1.1

http://i.imgur.com/QEu2dl.jpg
Scale: 1.2


All times are GMT -4. The time now is 08:37.

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