Raised This Month: $12 Target: $400
 3% 

Glow VIP Changer By Cows


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   ALL        Category:   Admin Commands       
Cows
Junior Member
Join Date: Aug 2006
Old 08-10-2006 , 11:03   Glow VIP Changer By Cows
Reply With Quote #1

this plugin will basically change anyone to a vip in any map.. also making them glow =) .. i generally made this plugin for knife fun .. but u can use it on any map.

cvars
sv_vip 1 = on

Commands
vCows <Target> - Sets Player To VIP
oCows <Target> - Removes Players VIP

Credits To Kensai And Raphero For Helping Me.
Attached Files
File Type: sma Get Plugin or Get Source (CowsVIP.sma - 802 views - 1.8 KB)
Cows is offline
SweatyBanana
BANNED
Join Date: Sep 2005
Location: LOL
Old 08-10-2006 , 11:05   Re: Glow VIP Changer By Cows
Reply With Quote #2

Change your commands...No one will understand why the name is vCows or oCows..


Common Mistake:
PHP Code:
 register_event("ResetHUD","RoundStart","be"
Should be:
PHP Code:
register_logevent("RoundStart"2"1=Round_Start"
and in your RoundStart function, you need to loop thru all players.


And in your oVIP function, you use cs_set_user_vip(PLAYER,0,0,0) when you should detect what team they are on and give them an appropriate model to go with their team, not a CT model because you could set a T to be the "VIP".

Last edited by SweatyBanana; 08-10-2006 at 11:15.
SweatyBanana is offline
Send a message via AIM to SweatyBanana Send a message via Yahoo to SweatyBanana
Cows
Junior Member
Join Date: Aug 2006
Old 08-10-2006 , 12:41   Re: Glow VIP Changer By Cows
Reply With Quote #3

yes but there is only a ct model of vip .. also how do you loop through all players?

Last edited by Cows; 08-10-2006 at 12:44.
Cows is offline
Cows
Junior Member
Join Date: Aug 2006
Old 08-10-2006 , 12:54   Re: Glow VIP Changer By Cows
Reply With Quote #4

Old RoundStart
Code:
public RoundStart(id)
{
 if(has_vip[id] == true)
 {
  set_user_armor(id,0)
  return 1
 }
 return 1
}
New RoundStart
Code:
public RoundStart(id)
{
 if ( has_vip[id] == true ) {
  while ( has_vip[id] == true ) {
   set_user_armor( id, 0 )
   } }
 return 1
}
would that work?
Cows is offline
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 08-10-2006 , 13:03   Re: Glow VIP Changer By Cows
Reply With Quote #5

Code:
public RoundStart()
{
    for(new i=1;i<=get_maxplayers();i++)
    {
        if(is_user_alive(i) && has_vip[i] == true) set_user_armor(i,0)
    }
}
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
Cows
Junior Member
Join Date: Aug 2006
Old 08-10-2006 , 13:11   Re: Glow VIP Changer By Cows
Reply With Quote #6

ok ty.
Cows is offline
VEN
Veteran Member
Join Date: Jan 2005
Old 08-11-2006 , 04:11   Re: Glow VIP Changer By Cows
Reply With Quote #7

You should unset VIP on every new round because all VIPs is spawn at the info_vip_start/info_player_start entity. Then you have to set VIP after player spawn again. If you have troubles with new round etc, read this New Round/Player Spawn/Round Start/Round End - do Not mess it

Also you should unset VIP model and remove scoreboard attribute on "oCows" command.

Last edited by VEN; 08-11-2006 at 07:48.
VEN is offline
Cows
Junior Member
Join Date: Aug 2006
Old 08-11-2006 , 11:11   Re: Glow VIP Changer By Cows
Reply With Quote #8

i pretty much changed the whole script that this plugin uses... so this is pretty much old.. also i cant get ur logevent round start to work so im just using resetHUD works great.. i dont know if it has bugs but, when im by myself i glow and vip model.. but when someone else comes in and it says game commence then it just stops and i dont get any glow.. so today ima try a few things, including:
Code:
register_logevent("logevent_round_start",2,"1 = game_commence"
ps: can i have ur aim/msn through pm?
Cows is offline
SweatyBanana
BANNED
Join Date: Sep 2005
Location: LOL
Old 08-11-2006 , 17:14   Re: Glow VIP Changer By Cows
Reply With Quote #9

ResetHUD is a big problem in cosing amxx plugins..

It is called many times in a round..sometimes up to 100..So use this function in your plugin_init() instead of the resetHUD call.

PHP Code:
register_logevent("yourRoundStartFunction"2"1=Round_Start"
SweatyBanana is offline
Send a message via AIM to SweatyBanana Send a message via Yahoo to SweatyBanana
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 08-11-2006 , 17:17   Re: Glow VIP Changer By Cows
Reply With Quote #10

we've already gone over this issue. He has changed it already in another version. Please read posts before commenting.
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
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 17:01.


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