mob
verb
Level_Up()
set category = "Mod"
proc/Levelup
just putting the proc wont run it it gives me 2 warnings and an error
Levelup :warning unused label
proc :warning unused label
error: missing expression
ID:270309
Mar 6 2006, 4:18 pm
|
|
mob just putting the proc wont run it it gives me 2 warnings and an error Levelup :warning unused label proc :warning unused label error: missing expression |
//if its for the world or anything in general. |
In response to Pyro_dragons
|
|
You can't have a caller for a global proc. To do what you want, you either need to include an argument, or make the proc under a different type path.
proc/LevelUp(mob/M) //Your global Level Up() proc with an argument |
In response to Pyro_dragons
|
|
neither way will work
|
Don't think it uncharitable to point this out, but: ID:438723. I think this thread pretty well proves you need to cover a lot more ground before you start writing demos. I recommend hitting the DM Guide pretty hard.
It's a good idea to write something for your own purposes, of course, so you can learn and then use that technique in your own games. However, if you want to publish an actual demo for other people to see, always run it by people who have some experience. For future reference. Lummox JR |
In response to Vito Stolidus
|
|
Vito Stolidus wrote:
No... like this. mob Try that. Or better yet, not. So very wrong. A levelup proc should never take an argument, because it never needs one. All such a proc needs is src, the mob leveling up. The correct way to call a levelup proc, therefore, is M.Levelup(). Lummox JR |
In response to Lummox JR
|
|
for some reason the code that was given by anyone didnt raise my level so i added
level += 1 to the end. Like this: proc/LevelUp(mob/M in world) //Your global Level Up() proc with an argument |
In response to Lummox JR
|
|
Oh, sorry. forgot. You're right.
--Vito |
In response to Mxjerrett
|
|
Mxjerrett wrote:
for some reason the code that was given by anyone didnt raise my level so i added level += 1 to the end. Gads no. The levelup() proc is supposed to do that part, not the verb that calls it. Lummox JR |
In response to Lummox JR
|
|
well for some reason it doesnt
|
In response to Mxjerrett
|
|
Why the hell do you pass an argument into Level() anyway.
|
In response to Mxjerrett
|
|
Mxjerrett wrote:
well for some reason it doesnt That's correct, because it was never put there. If you want to increment the level var, do it inside the levelup() proc, not outside. That's what the proc is for, after all. Common sense must be applied to these things. Lummox JR |
No... like this.
Try that.
--Vito