ID:273542
 
mob
proc
capcheck()
if(src.level>300 || src.rank="Genin")
src<<"You have reached the level cap & Your stats points have been reset!"
src.level=300
src.Skills()
return 0
if(src.level>=500 || src.rank="Chuunin")
src<<"You have reached the level cap & Your stats points have been reset!"
src.level=500
src.Skills()
return 0
if(src.level>=1000 || src.rank="Jounin")
src<<"You have reached the level cap & Your stats points have been reset!"
src.level=1000
src.Skills()
return 0


All three of these are ( " bad assignment " )

if(src.level>=1000 && src.rank="Jounin")
if(src.level>=500 && src.rank="Chuunin")
if(src.level>=1000 && src.rank="Genin")


Ok i believe i'm starting off in the right path but with coding 1 key or symbol can mess up a whole code... i need help
The " = " in your if() statements needs to be " == ".
In response to Nadrew
Fixed.. ok Thank you Nadrew
In response to Hokage Yondaime
            if(src.level>=500 && src.rank=="Genin")
src<<"You have reached the level cap & Your stats points have been reset!"
src.level=500
return 0
var/Ninvar=Mnin/10
var/Genvar=Mgen/10
var/Taivar=Mtai/10
level=round(Ninvar+Genvar+Taivar)
if(src.exp>=src.max_exp)
src.exp = 0
src.max_exp+=rand(0,15)
src.Mchakra+=rand(0,100)
src.taiexp+=rand(0,9)
src.ninexp+=rand(0,9)
src.genexp+=rand(0,9)
src.maxhealth+=rand(1,200)
src<<"<font size = 2><b><font color = blue>You leveled up!!"
src.maxhealth+=rand(1,11)
src.taiup()
src.ninup()
src.genup()
src.nin=src.Mnin
src.tai=src.Mtai
src.gen=src.Mgen


OK i had help to fic the capping part ( but for some reason ) now it say u reached your cap and it dont give stat but it still lets you kick logg ( and once you reach level up you gain a stat ) even through cap
In response to Hokage Yondaime
For the kicking log part you would prolly need some form a variable to check if you are the cap inside the actual kicking of the log part. cause if you don't do that you will always kick the log cause no where in that code does it say not to hit a log if capped (from what i can see)
In response to Hokage Yondaime
just put at the bottom leveling DM
if ((stat) >= (cap))
src.(stat) = (cap)


Yes only stops the stat from going over the cap when leveling but its still a start for you.

As for gear its roughly the same way.
In response to Hokage Yondaime
Hokage Yondaime wrote:
>           if(src.level>=500 && src.rank=="Genin")
> src<<"You have reached the level cap & Your stats points have been reset!"
> src.level=500
> return 0
> var/Ninvar=Mnin/10
> var/Genvar=Mgen/10
> var/Taivar=Mtai/10
> level=round(Ninvar+Genvar+Taivar)
> if(src.exp>=src.max_exp)
> src.exp = 0
> src.max_exp+=rand(0,15)
> src.Mchakra+=rand(0,100)
> src.taiexp+=rand(0,9)
> src.ninexp+=rand(0,9)
> src.genexp+=rand(0,9)
> src.maxhealth+=rand(1,200)
> src<<"<font size = 2><b><font color = blue>You leveled up!!"
> src.maxhealth+=rand(1,11)
> src.taiup()
> src.ninup()
> src.genup()
> src.nin=src.Mnin
> src.tai=src.Mtai
> src.gen=src.Mgen
>

OK i had help to fic the capping part ( but for some reason ) now it say u reached your cap and it dont give stat but it still lets you kick logg ( and once you reach level up you gain a stat ) even through cap


First thing I notice is that your level ups will be called every time you go past the level (300 level will be called when 500 level is checked also) unless the rank change's with the level up. But, other than that - why do you have a return 0 call in the middle of this proc and further action's after it? Anything after the return won't be called.