ID:142817
 
Code:
proc/GainLevel()//This is the procedue to the end of the attack verb
if(usr.Exp>=usr.MaxExp)//This checks to see if the usrs exp is = or > Than the Max Exp
usr.Level+=1//This adds one level to the usrs level stat
usr.Exp=0//This brings there Exp down to 0
usr.MaxExp+=20//This adds 20 to the persons max exp for them to gain a level
usr.Hp += 5//This gains the usrs Hp up by 5
usr.MaxHp += 5 //This does the same as the Hp thing but with the max hp
usr << "Your Hp has increased"//This just tells them there hp has increased
usr.Str += rand(3)//This adds 3 to the usrs strength
usr << "Your Str has increased by 3"//This tells the usrs that there str went up by 3
usr<<"You have gained a level. You now need [usr.MaxExp] Exp to gain another level."//This just tells the they gained a level and tells them how much they need to go


Problem description:

i got this piece of code from a friend.
when i try to compile it says this:

Procs.dm:1:warning: /turf/Weapon/verb.1.2/.call: value changed

Procs.dm:1:warning: /turf/Weapon/verb.1.2/.call: value changed

Procs.dm:1:error: proc: expected end of statement

Test.dmb - 1 error, 2 warnings (double-click on an error to jump to it)

When i choose to not use this part of coding in my game it says the same, but now with another source of the probs.
when i choose to not use that part, and try, its another part thats wrong.
but before it worked perfectly.
Does any1 know how i can solve it without deleting my game or a part of it?
Or can some1 give me the coding wich will do the same as this and nothing more?(so it will work)
none of those errors have to do with that coding.
In response to Deity Production 08
Deity Production 08????

what is likely to be the source of my probs?
or cant you see that without another part of the coding?
In response to Jan90ster9
double click the error messages and show me the every section that has an error
In response to Deity Production 08
that would give you a part of my source,
but, better to have a source that works than a faulty 1.

mob
var
xco
yco
zco
V

Part of code for saving.

mob
var
money

Login()
world<<"[usr] joins!"
usr.loc = locate(1,1,1)
usr.money = 200

Part of Loggin

area/Teleports
density=0
layer=3
invisibility=0

part of teleport section.

world
/turf/Start/
view = 8

part of world code
turf

Carpet_1
icon='Turf.dmi'
icon_state="1"

part of turf.

mob/var
Gold = 200
M = 0
Str = 9
Hp = 22

part of vars section
obj/
Sword//this is for when some one buys it the icon will be in the inventory slot
verb
Get()
set src in oview(1)
usr.contents+=new/obj/Sword
del src
//i put this in just in case some one drops it and some one else wants to get it
Drop()

part of my weapons section.

And then it says the same, the last 1.

Update: now it says 4 errors and 2 warnings.
New Update: i closed it down and opened it up again and now its back to "1 error and 2 warnings
I think the statement above the line indicated by the compile error is incomplete. That's the code that you didn't post that comes just before the code that you posted.
In response to Traztx
what line do you mean?
and if you mean above the line in the first message, there was none above.
it was the first line that was faulty(atleast it says that it is)
In response to Jan90ster9
Doubleclick on the error. That takes you to the place in the code where the system was expecting something else. Why was it expecting something else? Because a chunk of code above that line is incomplete.
In response to Jan90ster9
world
/turf/Start/


That /turf/Start/ is meaningless and shouldn't be there.

obj/


That / shouldn't be there, either.

            Get()
set src in oview(1)
usr.contents+=new/obj/Sword
del src


That's just the wrong way to do things. All you should do is src.Move(usr)
The usr abuse is a huge problem here, and it stems from the proc itself not even being defined correctly. You need to do this:

mob
proc/GainLevel()
//etc...


Then, replace EVERY usr in the proc with src.

And as for your errors, I've NEVER seen those warnings before, so you've done something VERY weird. Show us everything under /turf/Weapon.