Page 1 of 1
dice and cup script
Posted: Wed Nov 30, 2011 7:38 pm
by dragon slayer
I get this error msg when trying to use they dice and cup script
ERROR JS script failure: script Number <5020> Message <referenceError:
iDice1 is not defined
ERROR: filename: ./js/items/diceandcup.js
line number 9
error erroroneous line: <null>
token ptr: <null>
Posted: Wed Nov 30, 2011 7:46 pm
by dragon slayer
Nevermind i fixed it
here is the fix for dice and cup
Code: Select all
function onUseChecked( pUser, iUsed )
{
var iDice1 = RandomNumber( 1, 6 );
var iDice2 = RandomNumber( 1, 6 );
var pName = pUser.name;
if( iUsed.container != null )
pUser.EmoteMessage( pName+" rolls the dice and gets a "+iDice1+" and a "+iDice2+"." );
else
iUsed.TextMessage( pName+" rolls the dice and gets a "+iDice1+" and a "+iDice2+"." );
return false;
}
Posted: Wed Nov 30, 2011 7:55 pm
by Xuri
Doh. What a silly mistake to made, whoever made it.

Posted: Wed Nov 30, 2011 7:59 pm
by dragon slayer
hehe easy mistake
I'm working ona slotmachine script for you

using your dice and cup code and adding some tweaks i should have a nice slot machine