View Single Post
  #1  
Old 09-18-2005, 07:17 AM
Torankusu_2002 Torankusu_2002 is offline
'been round.
Torankusu_2002's Avatar
Join Date: Nov 2001
Posts: 1,246
Torankusu_2002 is on a distinguished road
Gralats class...

NPC Code:

if (created) {
setshape 1,32,32;
showcharacter;
//dontblock;
updategani();
}

if (updategani) {
updategani();
}

function updategani() {
type = 1;
//if (rupees>=350) type = 5;
//else
if (rupees>=100) type = 4;
else if (rupees>=30) type = 3;
else if (rupees>=5) type = 2;
setcharani gralats,#v(type);
}

if (rupees>1 || playerenters){
setcharprop #c,#v(rupees);
}


if (playertouchsme) {
playerrupees += rupees;
rupees = 0;
destroy;
}




This works for me.
The part I am having a problem with is this:
NPC Code:

if (rupees>1 || playerenters){
setcharprop #c,#v(rupees);
sleep 5;
setcharprop #c,;
}


That will show the amount of gralats that are there, and it will stop showing after .5 seconds, but it won't let the player pick them up anymore. Can anyone tell me why?
__________________
torankusu's
Reply With Quote