mob/var //varible testing
rpp=100
mob
Stat()
stat("RPP","[src.rpp]")
statpanel("Inventory",src.contents)
obj
StarterItems
IronMace1
icon='weapons.dmi'
icon_state="mace1"
IronMace2
icon='weapons.dmi'
icon_state="mace2"
IronMace3
icon='weapons.dmi'
icon_state="mace3"
var/list/RandomStarterItem = list("/obj/StarterItems/IronMace1", "/obj/StarterItems/IronMace2", "/obj/StarterItems/IronMace3"), //etc...//)
mob/verb/RandomStarterItem()
if(usr.rpp>=100)
usr.contents+=new pick(RandomStarterItem)
usr.rpp-=100
else
src<<"You need at-least 100 roleplay points."
return
Problem description:
Trying to have the player use their RPP to earn a random starting item. Not quite sure what I'm doing wrong.
loading random list.dme
main.dm:67:error: >=: bad variable definition
main.dm:67:error: if: invalid variable name: reserved word
main.dm:68:error: pick: undefined var
main.dm:71:error: "You need at-least 100 rpps.": bad variable definition
main.dm:71:error: src: bad variable definition
random list.dme:16:error: return: invalid variable name: reserved word
random list.dmb - 6 errors, 0 warnings (12/11/15 11:15 pm)
Also, you don't want those paths to be strings. You want them to be literal paths. Otherwise, you'll have to use text2path().