How can I tell the server to reset the playervar in quiestion once choosing to forget the skill?
Apart from that, the script works perfectly.
Code: Select all
Event( "OSDSelect", "Drill:Lskill1" )
{
if($playervar1 = 1)
{
osdcreate(OSDLIST,"No1","Sorry")
osdadditem(OSDTEXT,"","Sorry, but you're already a Drillmaster. There's nothing new we can teach you. Perhaps you could teach us.")
osdadditem(OSDEXITBUTTON,"Exit","Leave the temple")
osdactivate()
}
else
{
*grantskill %PLAYER% Drillmaster
*msg %PLAYER% You are now a Drillmaster
$playervar1=1
}
}
Event( "OSDSelect", "Mush:Lskill2" )
{
if($playervar2 = 2)
{
osdcreate(OSDLIST,"No2","Sorry")
osdadditem(OSDTEXT,"","Sorry, but you're already a Mushroom Farmer. There's nothing new we can teach you. Perhaps you could teach us.")
osdadditem(OSDEXITBUTTON,"Exit","Leave the temple")
osdactivate()
}
else
{
*grantskill %PLAYER% Mushroom Farmer
*msg %PLAYER% You are now a Mushroom Farmer
$playervar2=2
}
}
Event( "OSDSelect", "Chance:Lskill3" )
{
if($playervar3 = 3)
{
osdcreate(OSDLIST,"No3","Sorry")
osdadditem(OSDTEXT,"","Sorry, but you're already a Chancellor. There's nothing new we can teach you. Perhaps you could teach us.")
osdadditem(OSDEXITBUTTON,"Exit","Leave the temple")
osdactivate()
}
else
{
*grantskill %PLAYER% Chancellor
*msg %PLAYER% You are now a Chancellor
$playervar3=3
}
}
Event( "OSDSelect", "Cook:Lskill4" )
{
if($playervar4 = 4)
{
osdcreate(OSDLIST,"No4","Sorry")
osdadditem(OSDTEXT,"","Sorry, but you're already a Cook. There's nothing new we can teach you. Perhaps you could teach us.")
osdadditem(OSDEXITBUTTON,"Exit","Leave the temple")
osdactivate()
}
else
{
*grantskill %PLAYER% Cook
*msg %PLAYER% You are now a Cook
$playervar4=4
}
}