Jump to content

TrinityReclusive

Resident
  • Posts

    41
  • Joined

Everything posted by TrinityReclusive

  1. Ok I have a Box that emits a particle fog. The script in to works and sending the off/ on command works. I am trying to get a button on my hud i made to send the Turn On command to The Box. Here is the Box Script: integer channel = -200; string offMessage = "Fog Off"; string onMessage = "Fog On"; // Mask Flags - set to TRUE to enable integer glow = TRUE; // Make the particles glow integer bounce = FALSE; // Make particles bounce on Z plan of object integer interpColor = TRUE; // Go from start to end color integer interpSize = TRUE; // Go from start to end size integer wind = FALSE; // Particles effected by wind integer followSource = TRUE; // Particles follow the source integer followVel = TRUE; // Particles turn to velocity direction // Choose a pattern from the following: // PSYS_SRC_PATTERN_EXPLODE // PSYS_SRC_PATTERN_DROP // PSYS_SRC_PATTERN_ANGLE_CONE_EMPTY // PSYS_SRC_PATTERN_ANGLE_CONE // PSYS_SRC_PATTERN_ANGLE integer pattern = PSYS_SRC_PATTERN_ANGLE_CONE; // Select a target for particles to go towards // "" for no target, "owner" will follow object owner // and "self" will target this object // or put the key of an object for particles to go to key target = ""; // Particle paramaters float age = 6.8; // Life of each particle <-- invrease that value for larger fog float maxSpeed = 0.5; // Max speed each particle is spit out at float minSpeed = 0.5; // Min speed each particle is spit out at string texture = "4bdbb6c7-5819-b19e-be6d-38f96228fe68"; // Texture used for particles, default used if blank float startAlpha = 0.01; // Start alpha (transparency) value float endAlpha = 0.03; // End alpha (transparency) value vector startColor = <0, 0.5, 0>; // Start color of particles <R,G,B> vector endColor = <0, 0.5, 0>; // End color of particles <R,G,B> (if interpColor == TRUE) vector startSize = <1, 1, 1>; // Start size of particles vector endSize = <2.0,2.0,0.0>; // End size of particles (if interpSize == TRUE) vector push = <0.,0.,0.>; // Force pushed on particles // System paramaters float rate = .5; // How fast (rate) to emit particles float radius = 3; // Radius to emit particles for BURST pattern //////////////////////////////////////////////////////////////////// integer count = 30; // How many particles to emit per BURST <-- increase that value for more tense fog //////////////////////////////////////////////////////////////////// float outerAngle = 1.57; // Outer angle for all ANGLE patterns float innerAngle = 1.58; // Inner angle for all ANGLE patterns vector omega = <0,0,1>; // Rotation of ANGLE patterns around the source float life = 0; // Life in seconds for the system to make particles // Script variables integer flags; updateParticles() { flags = 0; if (target == "owner") target = llGetOwner(); if (target == "self") target = llGetKey(); if (glow) flags = flags | PSYS_PART_EMISSIVE_MASK; if (bounce) flags = flags | PSYS_PART_BOUNCE_MASK; if (interpColor) flags = flags | PSYS_PART_INTERP_COLOR_MASK; if (interpSize) flags = flags | PSYS_PART_INTERP_SCALE_MASK; if (wind) flags = flags | PSYS_PART_WIND_MASK; if (followSource) flags = flags | PSYS_PART_FOLLOW_SRC_MASK; if (followVel) flags = flags | PSYS_PART_FOLLOW_VELOCITY_MASK; if (target != "") flags = flags | PSYS_PART_TARGET_POS_MASK; llParticleSystem([ PSYS_PART_MAX_AGE,age, PSYS_PART_FLAGS,flags, PSYS_PART_START_COLOR, startColor, PSYS_PART_END_COLOR, endColor, PSYS_PART_START_SCALE,startSize, PSYS_PART_END_SCALE,endSize, PSYS_SRC_PATTERN, pattern, PSYS_SRC_BURST_RATE,rate, PSYS_SRC_ACCEL, push, PSYS_SRC_BURST_PART_COUNT,count, PSYS_SRC_BURST_RADIUS,radius, PSYS_SRC_BURST_SPEED_MIN,minSpeed, PSYS_SRC_BURST_SPEED_MAX,maxSpeed, PSYS_SRC_TARGET_KEY,target, PSYS_SRC_ANGLE_BEGIN,innerAngle, PSYS_SRC_ANGLE_END,outerAngle, PSYS_SRC_OMEGA, omega, PSYS_SRC_MAX_AGE, life, PSYS_SRC_TEXTURE, texture, PSYS_PART_START_ALPHA, startAlpha, PSYS_PART_END_ALPHA, endAlpha ]); } default { state_entry() { updateParticles(); llListen(channel, "", llGetOwner(), offMessage); } listen(integer channel, string name, key id, string message) { state off; //Switch to the off state } } state off { state_entry() { llParticleSystem([]); //Stop making particles llListen(channel, "", llGetOwner(), onMessage); } listen(integer channel, string name, key id, string message) { state default; } } AND Here Is What I Have on The Hud Button: default { state_entry() { llSay(-200,"Fog On"); } touch_start(integer total_number) { llSay(-200, "Fog On."); } } Wants Wrong Because it does not Trigger The Box Script.. I have try to figure this out but confused. Thanks for any help.
  2. This script is control by a hud i have made. All works well but.. I want to make sure that the item controlled by the hud only listens to the owner of the item. Example a (Box on the ground) listens to the hud. The hud makes the script in the box activate in this case reset. How to make the box only listen and react to the person who own it. Even if the other person has a similar item and a hud. In case two people own the same item and have the same hud. Does this make sense? everything works perfect but want to make sure this problem wont happen. This is the script in the item box on the ground. integer rocking = TRUE; default { state_entry() { llListen( -200, "", NULL_KEY, "All" ); // Listens on Channel 2 for command 'reset'. // Owner controlled only! // Change the channel to channels 2-254 only! // and "reset" to anything. llRegionSay(-200, "Active!"); } listen(integer channel, string name, key id, string m) { if(m == "reset") llRegionSay(-200, "Initializing..."); llResetOtherScript("Script Name"); // Make sure you rename this to the // script you want to reset! llRegionSay(-200, "Done!"); } }// END // I have try to put in (llGetOwnerKey(Id) == llGetOwner() but it breaks the script unless i am not puting it in the right place or wrong some how. Any ideas?
  3. Well somehow i bet i have some brackets missing or not in the right place on this script. I get error.. string dialogInfo = "\nPlease make a choice."; key ToucherID; key ToucherOwner; integer dialogChannel; integer listenHandle; default {state_entry() {dialogChannel = -200 - (integer)("0x" + llGetSubString( (string)llGetKey(), -7, -1) );} touch_start(integer num_detected) {ToucherID = llDetectedKey(0);ToucherOwner = llGetOwner();if (ToucherID == ToucherOwner) {llListenRemove(listenHandle);listenHandle = llListen(dialogChannel, "", ToucherID, ""); llDialog(ToucherID, dialogInfo, dialogChannel);llSetTimerEvent(60.0);}} listen(integer channel, string name, key id, string message) {if (message == "-"){} llListenRemove(listenHandle); // stop timer since the menu was clicked llSetTimerEvent(0); if (message == "Purple") {llRegionSay(-200,"Purple");} else {llRegionSay(-200,"");}} timer() {llSetTimerEvent(0); llListenRemove(listenHandle);llRegionSay(-200, "Sorry. You snooze you lose.");}} Your Help would be great if someone sees my error. Thank You
  4. Thanks it works now.. I always seem to get brackets wrong but getting better, Thank you all for your help. I would go nuts if it where not for your help on this thank you so much.
  5. Ok i changed it to this still runs but not for owner only. So i must have it still not correct. list buttons = ["-", "Red", "White", "Blue"]; string dialogInfo = "\nPlease make a choice."; key ToucherID; key ToucherOwner; integer dialogChannel; integer listenHandle; default { state_entry() { dialogChannel = 2 - (integer)("0x" + llGetSubString( (string)llGetKey(), -7, -1) ); } touch_start(integer num_detected) {if (ToucherID == ToucherOwner) { //open the dialog } ToucherID = llDetectedKey(0); llListenRemove(listenHandle); listenHandle = llListen(dialogChannel, "", ToucherID, ""); llDialog(ToucherID, dialogInfo, buttons, dialogChannel); llSetTimerEvent(60.0); // Here we set a time limit for responses } listen(integer channel, string name, key id, string message) { if (message == "-") { llDialog(ToucherID, dialogInfo, buttons, dialogChannel); return; } llListenRemove(listenHandle); // stop timer since the menu was clicked llSetTimerEvent(0); if (message == "Red") { llSay(2,"Red"); // process Red here } else if (message == "White") { llSay(2,"White"); // process Green here } else { llSay(2,"Blue"); // do any other action here } } timer() { // stop timer llSetTimerEvent(0); llListenRemove(listenHandle); llWhisper(0, "Sorry. You snooze; you lose."); } }
  6. Well this script does what it should but i can not seem to get it for owner only. The script runs fine but still anyone can use it. Do I have something in the Dialog listen area wrong or left out? ist buttons = ["-", "Red", "White", "Blue"]; string dialogInfo = "\nPlease make a choice."; key ToucherID; key ToucherOwner; integer dialogChannel; integer listenHandle; default { state_entry() { dialogChannel = 2 - (integer)("0x" + llGetSubString( (string)llGetKey(), -7, -1) ); } touch_start(integer num_detected) { ToucherID = llDetectedKey(0); ToucherOwner = llGetOwner(); llListenRemove(listenHandle); listenHandle = llListen(dialogChannel, "", ToucherID, ""); llDialog(ToucherID, dialogInfo, buttons, dialogChannel); llSetTimerEvent(60.0); // Here we set a time limit for responses } listen(integer channel, string name, key id, string message) { if (message == "-") { llDialog(ToucherID, dialogInfo, buttons, dialogChannel); return; } llListenRemove(listenHandle); // stop timer since the menu was clicked llSetTimerEvent(0); if (message == "Red") { llSay(2,"Red"); // process Red here } else if (message == "White") { llSay(2,"White"); // process Green here } else { llSay(2,"Blue"); // do any other action here } } timer() { // stop timer llSetTimerEvent(0); llListenRemove(listenHandle); llWhisper(0, "Sorry. You snooze; you lose."); } } I hope some one can notice what i have wrong of missed. Thank you for your help
  7. Well i took out the (integer ) line but now it gives me error on line 23, 4. integer handle; default { state_entry() { handle = llListen( 0, "", llGetOwner(), "fire" ); vector rootRot = llRot2Euler(llGetRootRotation()); vector mod = <llFrand(-0.2), llFrand(0.2), 0> + <0, -0.1, 0>; rotation rot = llEuler2Rot( rootRot + mod ); integer n = llGetInventoryNumber( INVENTORY_OBJECT ); integer choice = llFloor( llFrand(n) ); string name = llGetInventoryName(INVENTORY_OBJECT,choice); llRezObject(name, llGetPos(), <0,0,15>*rot, ZERO_ROTATION, 12); } } listen(integer channel, string name, key id, string message) { llSay(0, name + " just said " + message); } } This is giving me headache lol
  8. Sorry have to admit i an not to bright. Tried reading about llListen could not make heads or tails of it. Tried to add that command to it but it didn't work. This is what i tried to add i know its wrong have error on line..10 9 integer handle; default { state_entry() { handle = llListen( 0, "", llGetOwner(), "fire" ); (integer ) vector rootRot = llRot2Euler(llGetRootRotation()); vector mod = <llFrand(-0.2), llFrand(0.2), 0> + <0, -0.1, 0>; rotation rot = llEuler2Rot( rootRot + mod ); integer n = llGetInventoryNumber( INVENTORY_OBJECT ); integer choice = llFloor( llFrand(n) ); string name = llGetInventoryName(INVENTORY_OBJECT,choice); llRezObject(name, llGetPos(), <0,0,15>*rot, ZERO_ROTATION, 12); } } listen(integer channel, string name, key id, string message) { llSay(0, name + " just said " + message); } } I Admit i am new to understand some of this never did a listen command before.
  9. How to get this script to trigger on a text chat message. What to trigger it by using chat window. I am stuck i tried different things but i can not get it right. Is it possible to do this? I been searching for a way but can not find a clear answer for this. The click on touch works fine. But wish to active this script on a chat command such as the word fire. I appreciate you help. Thank you. default { touch_start(integer total_number) { if(llDetectedKey(0)== llGetOwner()) { vector rootRot = llRot2Euler(llGetRootRotation()); vector mod = <llFrand(-0.2), llFrand(0.2), 0> + <0, -0.1, 0>; rotation rot = llEuler2Rot( rootRot + mod ); integer n = llGetInventoryNumber( INVENTORY_OBJECT ); integer choice = llFloor( llFrand(n) ); string name = llGetInventoryName(INVENTORY_OBJECT,choice); llRezObject(name, llGetPos(), <0,0,15>*rot, ZERO_ROTATION, 12); } } }
  10. Great that fixed it thought it might have been something simple i still get brackets messed up some-days. But still learning Thanks alot hope you have a great day!
  11. I need a bit of help. How to add owner only to this script so only the only can activate it. integer CountDownTime = 60; float CountDownIncrements = 1; integer StartTime; integer Rounds; // Script starts here .... default { touch_start(integer numbb) { llSay(0, (string)CountDownTime + " ..."); llSetTimerEvent(CountDownIncrements); StartTime = llGetUnixTime(); } timer() { if (llGetUnixTime() >= StartTime +CountDownTime) { llSay(0, "Bang"); llSetTimerEvent(0); } else { Rounds++; llSay(0, (string)(CountDownTime - Rounds) + " ..."); } } } The script works fine but want it to only be run by the owner. I tried to add { if (llDetectedKey(0)==llGetOwner()){ to it but then i get a syntax error on the timer. Please help thanks a bit new to scripting but somewhat figured it out.
  12. Parcels for rent. Witches and Wizards Realm is a RP Residential Estate featuring scenery and landscaping to fit this style theme. Normals, Wizards, Witches, Fairies. Elves and Furries are welcome to play and rent. Group Castle is used for partys and many community events are held weekly. http://maps.secondlife.com/secondlife/Soul%20Keeper/63/152/31 Lot #1A 258 Prims Price 518L 896m2 Lot 7A 291 Prims Price 582L 1008m2 Lot 7 B 221 Prims Price 436L 768m2
  13. Parcels for rent. Witches and Wizards Realm is a RP Residential Estate featuring scenery and landscaping to fit this style theme. Normals, Wizards, Witches, Fairies. Elves and Furries are welcome to play and rent. http://maps.secondlife.com/secondlife/Soul%20Keeper/63/152/31 Lot #1A 258 Prims Price 518L 896m2  Lot 7A 291 Prims Price 582L 1008m2  Lot 7 B 221 Prims Price 436L 768m2 
×
×
  • Create New...