Give_Gold()
if (usr.BattleNum != 0)
usr << "You're in a fight!"
return
var/list/Players = new()
var/mob/M
for(M in world)
if (M != usr && !M.AFK && !M.BattleNum && !usr.Challenged && !M.Challenged)
if (M.client && M.Hp > 0 && M.MaxHp > 0 && (usr.TeamNum != M.TeamNum || usr.TeamNum == 0))
Players += M
Players += "Cancel"
usr.Challenged = 1
M = input("Who do you wish to give gold to?", "Give Gold", null) in Players
if (length(Players) <= 1)
usr << "Either your alone, or everyone is AFK or battling!"
if (M == "Cancel")
usr.Challenged = 0
return
Problem description:its not sending gold for some reason it use to work but now its broke or something plese help me
I read through your code...I didn't see anything that increased one players gold or decreased the other's. It was pretty much just a lot of checks to see if the player could receive the gold, with nothing included to actually give the gold.
Something else I might add in is that, since you are using usr to as a reference to the mob that calls the proc or verb Give_Gold, it should be safer and wiser to use src in place of usr.
Hiead