Jump to content

Ares Halostar

Resident
  • Posts

    99
  • Joined

  • Last visited

Everything posted by Ares Halostar

  1. Only problem with llSetTextureAnim is that it has that annoying tick after every rotation. Plus when the texture stops, I need to query the position that the texture stops, to determine the finished angle of rotation so I can calculate what the winnings are (BTW this project does not pay or accept money, it is just a project I am working on). Also noted that the "radian" is actually a float that is required by the function : llSetLinkPrimitiveParamsFast(LINK_THIS,[PRIM_GLOW, ALL_SIDES, 0.1,PRIM_TEXTURE,ALL_SIDES,"roulette_image copy",<1,1,0>,<0,0,0>,Rotate]);
  2. I am trying to make a script that uses llSetLinkPrimitiveParamsFast with PRIM_TEXTURE to rotate a texture. Here is what I have so far. integer WHEEL = 4; float Rotate = PI; default { link_message(integer sender_num, integer num, string str, key id) { if (str == "Spin") { integer count = 0; while(count<llFrand(50.0)) { Rotate = Rotate + count; llSetLinkPrimitiveParamsFast(LINK_THIS,[PRIM_GLOW, ALL_SIDES, 0.1,PRIM_TEXTURE,ALL_SIDES,"roulette_image copy",<1,1,0>,<0,0,0>,Rotate]); llSetLinkPrimitiveParamsFast(LINK_THIS,[PRIM_GLOW, ALL_SIDES, 0.0]); ++count; } } } } I am basically trying to spin a wheel around a few times, and have it stop randomly in a different spot every time it is spun. Any help would be appreciated.
  3. Thanks for all your replies. And yes Void, I think you are right. To Peter, the game is hosted on a built Arena in the air. I thought that if I could count two quick left clicks on the floor of the arena, I could detect double click teleporting, but looks like the viewer is intercepting the second click. Also, setting a landing point was discussed, but most users of the sim wanted to use double click teleporting in everyday use, so we won't be setting a landing point unfortunately.
  4. Sorry to be a pain Void and thank you for your help, but I tried it both ways, with greater than or less than. One way gives a result with one or two clicks.. the last suggestion gives no results. default{ touch_end( integer vIntTch ) { if (llGetTime() < 0.5) { llSay(0,"Double Clicked"); } else { llResetTime(); } }}
  5. I tried your script, but it will detect every touch, and not just two touches. Unfortunately we can't have the people playing the game to wear a prim that would detect speed/position.. that would have been a nicer option, but was deemed unworkable. Just a simple script to detect when a prim is touched twice in succession, then reset it's counter/timer.
  6. We have a game that involves a lot of movement in an arena, but it is ruined by people cheating by double click teleporting to cover distances quickly. I am messing with a basic script that will detect when a prim is clicked twice in succession, but I am having problems with the touch event possibly not detecting fast enough, or my script logic is wrong. Can someone please look at my script and tell me where I am going wrong. integer Increment = 0; default { state_entry() { Increment = 0; } touch_start(integer total_number) { Increment +=1; if(Increment>=2) { llSetTimerEvent(0.0); llSay(0,"Touched Twice"); Increment = 0; } } touch_end(integer total_number2) { llSetTimerEvent(1.0); if(Increment>=2) { llSetTimerEvent(0.0); Increment = 0; } } timer() { llSetTimerEvent(0.0); llSay(0,"Timer is working. Increment = "+(string)Increment); Increment = 0; } }
  7. Clicking on Recent Items in your inventory will often force an inventory reload. I have noticed these problems with TPV viewers only though.
×
×
  • Create New...