Jump to content

Casey Conundrum

Resident
  • Posts

    9
  • Joined

  • Last visited

Reputation

0 Neutral

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. I was thinking about a force sit, but force-sit would apply if there in rlv, while some of the items we are making have the force sit command being used, this is on a gated area and only applies if they bump into the fence.
  2. the better idea would to say use move to target to keep them in place while its posing to stop them from moving?
  3. This pose & script are both in a hud that a user will wear. so sitting to stop movement will not work in the system. the idea is I have fence that sends a message to the hud, you have touched the fence. So the hud will send a zap to the hud user zapping them for a amount of time. during that time frame I don't want them to be able to move while being zapped. IE while the pose is being played.
  4. About to pull my hair our rofl. A) I can get the pose to start, but when its time to stop it, it fails to stop and sometimes gives us "Script trying to trigger animations but PERMISSION_TRIGGER_ANIMATION permission not set". B) under take control how would I take control where the said person can not move till time releases controls? just not sure what to add in the control event string animation = "Pose"; trigger() { //-- Removed not a problem -- //little hidden code //-- end of Removed not a problem -- llRequestPermissions(llGetOwner(),PERMISSION_TRIGGER_ANIMATION); } default { state_entry() { } run_time_permissions(integer perm) { if(PERMISSION_TAKE_CONTROLS & perm) { llTakeControls(CONTROL_FWD |CONTROL_BACK |CONTROL_LEFT |CONTROL_RIGHT |CONTROL_ROT_LEFT |CONTROL_ROT_RIGHT |CONTROL_UP |CONTROL_DOWN |CONTROL_LBUTTON |CONTROL_ML_LBUTTON ,TRUE, TRUE); } if (perm & PERMISSION_TRIGGER_ANIMATION) { list anims = llGetAnimationList(llGetOwner()); if(llListFindList(anims, [llGetInventoryKey(animation)]) == -1) { llStartAnimation(animation); } } } timer() { //-- Removed not a problem -- //little hidden code //-- end of Removed not a problem -- if (amounta == amountb) { // Stop the timer. llSetTimerEvent(0.0); llStopAnimation(animation); llReleaseControls( ); } } }
  5. Thanks Wulfie seems to be working so far with this code. But if I run into trouble I will ask again on it integer subtract(integer x, integer y) { integer a; if(x < y) { integer z = ShowAbsolute(x - y); a = y - z; return a; } else { return x - y; } } integer ShowAbsolute(integer inputInteger) { integer A = llAbs(inputInteger); return A; } default { state_entry() { llOwnerSay((string)subtract(10, 11)); } }
  6. llAbs would work just fine, but on the math end of lsl I just don't know how I would be able to tell hey I can only give you 10 of the 11 your asking for.
  7. I this always worked for me in the past when I was doing demos on scripted items. I don't recommend using PARCEL_DETAILS_NAME all someone has to do is go to there own land and rename it and the script will work just fine for them. string Allow_Region = "Your Region Name"; integer Permission(string region) { integer hasPermission = FALSE; if (region == Allow_Region) { hasPermission = TRUE; } return hasPermission; } default { changed(integer change) { string region = llGetRegionName(); if (change & CHANGED_OWNER) { llResetScript(); } if (change & CHANGED_REGION) { if (Permission(region) == TRUE) { } } if (change & CHANGED_TELEPORT) { if (Permission(region) == TRUE) { } } if (change & CHANGED_REGION_START) { if (Permission(region) == TRUE) { } } } }
  8. Hello all! I needing some help on a script, I know it has to be pretty simple but I'm just not seeing it my self. I'm trying to return a positive when subtracting from a given number even when its returns a negative number. I just can't rap my head around lsl and math. I was able to get it to this point integer subtract(integer x, integer y) { if( x < y ) return 0; else return x - y; } default { state_entry() { llOwnerSay((string)subtract(10, 11)); } } but the system I working on works on positive returns and returning 0 throws off my system when I just want to remove what the system has. IE Object A is asking to remove 11 from Object B, but Object B only has 10 Units, So Object B would send back it was only able to remove 10 Units so it would tell Object A 10 was removed.
×
×
  • Create New...