Hi, this newbie has a simple and maybe silly question... i've been working in a simple HUD to trigger animations but i got an error when trying to stop the last anim... using the variable LastPlayed... can you help me please? ty
touch_start(integer total_number)
{
llRequestPermissions(llDetectedOwner(0), PERMISSION_TRIGGER_ANIMATION);
string nameLinked = (string)llGetLinkName(llDetectedLinkNumber(0));
if (nameLinked == "01z")
{
llSetLinkPrimitiveParamsFast(1,[PRIM_ROT_LOCAL,llEuler2Rot(<PI/2,0.0,0.0>)*llGetLocalRot()]);
}
else if (nameLinked == "02z")
{
llSetLinkPrimitiveParamsFast(1,[PRIM_ROT_LOCAL,llEuler2Rot(<-PI/2,0.0,0.0>)*llGetLocalRot()]);
}
else if (nameLinked == "01a")
{
llStopAnimation(LastPlayed);
}
else if (nameLinked == "02a")
{
llStartAnimation("anim");
string LastPlayed ="anim";
}