var Itemname = “Oak log”;
var Itemdiscription = “some something to keep chills away”;
var Itemworth = “worth-100gp”;
var ItemBox = 1;
var ItemBoxWidth = 300;
var ItemBoxHeight = 235;
var ItemBoxsize = 100;
var ItemBoxsize1 = 100;
var Buttonwidth = 200;
var Buttonheight = 235;
var Buttonsize = 80;
var Buttonsize1 = 25;
var Text1 = “Description”;
var Buttonwidthx = 200;
var Buttonheightx = 260;
var Buttonsizex = 80;
var Buttonsize1x = 25;
var Text2 = “Drop”;
var details : boolean = false;
function start(){
function OnTriggerEnter(other : Collider){
if(other.tag == "Player"){
details = true;
}
}
function OnTriggerExit(other: Collider){
if(other.tag == "Player"){
details = false;
}
}
if ( = true){
function update
}
}
function update(){
function OnGUI(){
GUI.Box(Rect(ItemBoxWidth, ItemBoxHeight, ItemBoxsize, ItemBoxsize1), Itemname);
GUI.Label (Rect (300, 24, 100, 100), Itemdiscription);
GUI.Label (Rect (75, 130, 100, 100), Itemworth);
//text color
GUI.color = Color.white;
if (GUI.Button(Rect(Buttonwidth,Buttonheight,Buttonsize,Buttonsize1), Text1));
//Button
if (GUI.Button(Rect(Buttonwidthx,Buttonheightx,Buttonsizex,Buttonsize1x), Text2));
}
}