This has been giving me so much trouble. I want a vebr that will let you select from a list of objects (which already works) and creates that object depending on the objects difficulty var. Unfortuneately, the list has to be limited to objects that have a certain difficulty var compared to a skill var on the client. Here's the code. I think you can tell what I want, the problem is in bold.
icon = 'Wood.dmi'
Quality = 0
set src in oview(1)
set src in view(3)
usr << "This woood's quality is [src.Quality]."
Craft(C in usr.Woodcrafts)
if(usr.Woodworking + rand(0,100) >= C.difficulty)
new C (usr)
usr << "You made a [C]!"
usr << "You failed to make a [C]."
icon = 'Fishing Rod.dmi'
difficulty = 75
The problem is, C.difficulty is an undefined var. How can I set this up so it works? If it's not clear how I want it to work, I'll clarify for you.
May 9 2002, 12:17 pm