mob
verb
Add_Ability()
set category = "Orders"
var/abilityadded
if(abilityadded == 1)
usr << "This item has already an ability placed!"
else
switch(input("Which type of ability do you want to add to this item?", "Ability Add:",text) in usr.contents in list ("Attack","Cancel")) //This is where I need to have the objs that you are carrying to be used in Ability Add
if("Attack")
if(usr.abilityadding <= 19)
usr << "<font color=red>You need a higher Ability Adding skill!"
if(usr.abilityadding >= 20)
var/attackadd = input("How much Attack will you add?") as num|null
if(attackadd < 0)
usr << "You cannot do that!"
if(attackadd > 0)
usr.random = rand(1,200)
if(usr.random == usr.abilityadding * 3)
usr << "You fail to add any abilities to this item, try again!"
if(usr.random == usr.abilityadding * 3)
usr << "You added your strength, to the item or weapon!"
usr.str -= 10
usr.abilityadding += 1
if("Cancel")
usr<<"You decided not to."
return
Edit: I fixed the inventory thing. But now, it won't let me add the Attack in.
This is not a valid statement. I don't know why it didn't give you any compile errors, but it should. My question to you is, why have the players choose an item from their inventory if you never do anything with it? And you know that your setup will allow you to increase the player's Attack forever?
That would be a proper statement. You can't do two "in list"s in the same input(), only one. Since you never use the items in the player's inventory, I don't see why you're including them here, so I removed the in usr.contents part. Also, your input() ended with the word "text", for some reason. I think you assume that means the input should be text, but the input() doesn't work like that. For lists, there are only two types of input you can accept, "as null | anything". The last position there indicates which item in the list would be the default one highlighted, not the type of choice the input can accept.
When the input box pops up, it will have a Cancel button on it because of the "as null|anything" part. The item highlighted would be "One", because the last argument in the input() is "One". The rest you seem ok on, so I won't go into it.
I hope that helps.
~X