ID:146919
 
Here you see, is my wizard class shop coding, im having a problem, ive tried to fix it but i cant when your the wizard class it will not let you shop in your basic weapons(below) can someone look through and see if anything is wrong?
//Create the item list for wizards
if (Class == "Wizard"||Class=="Spellsword")
ItemName += "Oak Staff"
ItemName += "Metal Staff"
ItemName += "Magic Staff"
ItemName += "Staff of Knowledge"
ItemName += "Staff of Wisdom"
ItemRef += /obj/equipment/Weapons/Staff/Stf1
ItemRef += /obj/equipment/Weapons/Staff/Stf2
ItemRef += /obj/equipment/Weapons/Staff/Magic_Staff
ItemRef += /obj/equipment/Weapons/Staff/Staff_of_Knowledge
ItemRef += /obj/equipment/Weapons/Staff/Staff_of_Wisdom
//Set the cost of the items
for (var/A=1; A <= length(ItemName);A++)
ItemCost += 10 * (length(ItemName) ** A)
WeaponList += "[ItemName[A]] - [num2text(ItemCost[A], 50)]"
// src wants to buy, so find the item
for (var/I=1; I <= length(ItemName);I++)
// we found the item, now let's create it
if (BuyItem == "[ItemName[I]] - [ItemCost[I]]")
var/BuyChoice=alert("This item costs [ItemCost[I]]. Are you sure you want it?", "Item Shop", "Yes", "No")
if (BuyChoice == "No")
return
else if (Gold < ItemCost[I])
src << "You're short on gold!"
return
src << "You bought \a [ItemName[I]]"
src.Gold -= ItemCost[I]
var/obj/O=ItemRef[I]
new O (src)
Tag your code with the dm tags when posting on the forums.

Also- what's going wrong with you?
Care to give us an error readout? Or does it just not work?
And if so, what is it *meant* to do, and what *does* it do?
In response to Elation
no error/ warnings, and when u dbl click Basic Weapons it just goes back the the screen and its like nothing happend
In response to Derekjeterisgod
Check if the "Double weapons" proc is linking to whatever you want it to do correctly.

Sorry, I really can't help, I'm too stupid...
In response to Elation
ok thnx anyways