scroll of respawn gives mp_startmoney
Moderator: Forum Moderator
scroll of respawn gives mp_startmoney
yo, when people on our server use scroll of respawn, they always get 16000 $ (thats what our mp_startmoney is set to)
is there a way to let the players stick with the amount of money they got before respawning? its causing some trouble cuz some people abuse this and turn the server into some kind of deathmatch server
restricting shopmenu to buyzone and buytime wont help tho - we got 30 seconds buytime, and thats some serious long time when you think about it
is there a way to let the players stick with the amount of money they got before respawning? its causing some trouble cuz some people abuse this and turn the server into some kind of deathmatch server
restricting shopmenu to buyzone and buytime wont help tho - we got 30 seconds buytime, and thats some serious long time when you think about it
- nightscream
- Sorceress
- Posts: 319
- Joined: Wed Jul 06, 2005 12:54 pm
- Location: Belguim, Hallaar
- Contact:
- Nitricacid
- Peon
- Posts: 49
- Joined: Tue Jul 12, 2005 1:21 pm
well, it did for us, and the code clearly tell that it works this way.
just look at other.inl, line 416 - its there...
it checks the server settings what mp_startmoney is set to.
when you run mod dod, there is no such cvar so the plugin sets a "fake-startmoney", check your wc3FT.cfg.
then, when you respawn, and your current money is lower then mp_startmoney, it reassignes you the full mp_startmoney.
now i found out that removing this 10 lines obviously messed our whole server up, we get a whole bunch of errors that pop up all over the place so i highly recommend not to do this, check my other thread
just look at other.inl, line 416 - its there...
Code: Select all
public func_spawn(parm[2]){
#if ADVANCED_DEBUG
writeDebugInfo("func_spawn",parm[0])
#endif
if (endround){
set_user_money(parm[0],get_user_money(parm[0])+itemcost2[0],1)
return PLUGIN_HANDLED
}
new id = parm[0]
if(!p_data_b[id][PB_ISCONNECTED])
return PLUGIN_CONTINUE
if(get_user_team(id)==UNASSIGNED)
return PLUGIN_CONTINUE
p_data[id][P_ITEM]=0
p_data[id][P_ITEM2]=0
if (is_user_alive(id))
return PLUGIN_CONTINUE
new team[32]
get_user_team(id,team,31)
p_data_b[id][PB_PLAYERSPAWNED]=true
Ultimate_Icon(id,ICON_SHOW)
spawn(id)
p_data_b[id][PB_SLOWED]=false
p_data_b[id][PB_STUNNED]=false
spawn(id)
set_task(0.3,"spawn_player",TASK_SPAWNPLAYER+id,parm,2)
set_task(0.5,"player_giveitems",TASK_GIVEITEMS+id,parm,2)
#if MOD == 0
give_item(id, "weapon_knife")
#endif
[color=red]
new money = get_user_money(id)
#if MOD == 0
if (money < get_cvar_num("mp_startmoney"))
set_user_money(id,get_cvar_num("mp_startmoney"),0)
#endif
#if MOD == 1
if (money < iCvar[DOD_STARTMONEY])
set_user_money(id,iCvar[DOD_STARTMONEY],0)
#endif
[/color]
return PLUGIN_CONTINUE
}
when you run mod dod, there is no such cvar so the plugin sets a "fake-startmoney", check your wc3FT.cfg.
then, when you respawn, and your current money is lower then mp_startmoney, it reassignes you the full mp_startmoney.
now i found out that removing this 10 lines obviously messed our whole server up, we get a whole bunch of errors that pop up all over the place so i highly recommend not to do this, check my other thread
- ferret
- Lead Warcraft 3 XP Developer
- Posts: 422
- Joined: Wed Jul 06, 2005 8:20 am
- Location: Atlanta, GA
- Contact:
Quoted. This is to say "I agree"Geesu wrote:FYI, there is no way removing those lines would cause any errors :/
-< www.gamehavoc.com >-
Lazarus Long: And I know you didn't because the Server Files are version 2.2.6 and the file you posted is version 2.2.5, so do as I told you above and don't ever lie to me again or help is gone!
Lazarus Long: And I know you didn't because the Server Files are version 2.2.6 and the file you posted is version 2.2.5, so do as I told you above and don't ever lie to me again or help is gone!