Jump to content

Altier Verwood

Resident
  • Posts

    90
  • Joined

  • Last visited

Everything posted by Altier Verwood

  1. Oh my this sounds like a painful process, I've noticed the sit position of the pilot changes the rotation point of the vehicle, I was hoping I could just set it to the location of the root prim rather than the sit position. could there be a way to get that location easily without all the testing? or is this really trial and error?
  2. Hello There Sl Forum people, I am having a bit of a problem with my tiny 100th scale air craft, it's very hard to get the rotation point at the center, because it is rotating at the avatar sit point, can I change it in the script to rotate at the rot prim? if so, how can I do that? thank you very much for any help.
  3. Thank you so much for this, you saved my project, I was getting so frustrated with the ray not hitting what i wanted!
  4. it looks like you were right, I had to add llGetCameraPos()+<5,0,0>*llGetCameraRot() to the "start"
  5. but i have that already in the cast ray? do i need to do it again? list results = llCastRay(start, start+<range,0.0,0.0>*llGetCameraRot(),[RC_REJECT_TYPES,RC_REJECT_LAND,RC_DETECT_PHANTOM, FALSE,RC_DATA_FLAGS,RC_REJECT_PHYSICAL, TRUE,RC_GET_ROOT_KEY,RC_MAX_HITS,15]);
  6. Oh thank you for the replay! would you be able to elaborate on what i did wrong with the llGetCameraPos()+<5,0,0>; ? how would i multiply that as you said?
  7. Hey there LSL people, I am working on a vehicle with a raycast weapon on it, and I have it kind of working using this. But I've run into a problem, when aiming straight a head the ray is blocked by something? but since i can't see the ray it's hard to tell whats blocking it. is there a way I can move the start of the ray projection forward by like 5 meters? I tried adding llGetCameraPos()+<5,0,0>; but that doesn't seem to work either the ray just doesn't hit anything at that point. vector start = llGetCameraPos(); list results = llCastRay(start, start+<range,0.0,0.0>*llGetCameraRot(),[RC_REJECT_TYPES,RC_REJECT_LAND,RC_DETECT_PHANTOM, FALSE,RC_DATA_FLAGS,RC_REJECT_PHYSICAL, TRUE,RC_GET_ROOT_KEY,RC_MAX_HITS,15]); llSleep(0.03); key target = llList2Key(results,0); llTriggerSound(fire_sound, 1.0); llResetOtherScript("Bolt1"); llRegionSayTo(target,gTargetChan, damage_type); llResetOtherScript("m_f"); llSleep(delay);
  8. Hey there, thank you for your help, I just figured it out a few hours ago after so much trial and error. its these two lines right here that are what did it, but the explanation of what they do it really bad on the wiki, so i wasn't understanding it. llSetCameraEyeOffset(<-5.0, -0.00, 2.0> ); //llSetCameraAtOffset(<3.0, 0.0, 2.0> ); llSetCameraAtOffset(<0.0, 0.0, 0.0> );
  9. Ah, yes that is what i thought, but nothing i do works, i tried many things today and I'm burning out fast, not one has posts any answers clearly anywhere on how to get a camera to follow the rotation of a prim that changes its pitch, or how to get a camera to always stay behind an object, i know it's possible because i have several no mod planes that do it. i want the camera to always stay behind the flying plane no matter what direction it's going, seems like a huge failure on LL's part to make the camera controls so bad in this game. can i change the camera based on the rotation of the root prim? if so how would i do that? I've tried using llgetpos and llgetrot for the paramiters but it just comes back with a syntex error.
  10. I've been searching for hours so far and have not found the solution to this. I have a vehicle script I'm working with, and it has a line in it to control the camera, i zeroed everything out, and it works kind of, when i fly to the left or right the camera stays behind the vehicle, but when i fly up or down the camera stays locked on the vehicle, and does not give me a good view of where i am going. here is the line, i don't know what line to change, i zeroed everything so there should be no lag no offset. list camNoOffset =[CAMERA_ACTIVE, TRUE,CAMERA_BEHINDNESS_ANGLE, 0.0,CAMERA_BEHINDNESS_LAG, 0,CAMERA_DISTANCE, 0.0,CAMERA_PITCH, 0.0,CAMERA_FOCUS_LAG, 0,CAMERA_FOCUS_LOCKED, FALSE,CAMERA_FOCUS_THRESHOLD, 0.0,CAMERA_POSITION_LAG, 0.0,CAMERA_POSITION_LOCKED, FALSE,CAMERA_POSITION_THRESHOLD, 0.0,CAMERA_FOCUS_OFFSET, <0,0,0>]; any help on this would be appreciated.
  11. I'm sorry, let me try to explain better, The first object is CGCHS Flood Marine NPC, we will call that one the Target. the second object is CGCS Halo Ground Meter 2.7 we will call that one the Receiver. how the script works is this The receiver fires a ray with a message on channel -943, the Target gets that and does this hp -=llRound(llFrand(Assault_RifleD)+Assault_RifleMD);, and fires back llRegionSayTo(llGetOwnerKey(id),-943,"Assault_Rifle"); The Receiver is listening for that return message the llregionsay. the problem i have run into is the Target, can not do both llRegionSayTo(llGetOwnerKey(id),-943,"Assault_Rifle"); AND hp -=llRound(llFrand(Assault_RifleD)+Assault_RifleMD); at the same time, it picks randomly what one to do. Okay on further testing it was this, I put the receiver script in another object i was wearing, not the one i was wearing that cast the ray, I thought that it would get the ID of my avatar and not the object casting the ray because I was wearing the object, I was wrong. when I put the receiver script in the same prim the cast the ray, it now works, this is a step forward but not the outcome I was looking for. I need to test more and see if I can make some adjustments.
  12. So after much testing, I can not figure this out, it seems completely random, I tried splitting it into two scripts where each listens for a different channel, it didn't work. if (m == "Assault_Rifle") { //integer chance = llRound(llFrand(100)); //if(chance>=Assault_Rifle+Global) { llRegionSayTo(id, -943, "Assault_Rifle"); llOwnerSay(id); llOwnerSay(m); llSleep(.1); } this is basically what happens, it will do one or the other not both. it will either do the region say or the owner say, and if i take out the owner say, it will only some times do the region say. [17:31] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [17:31] CGCSH Flood Marine NPC 2.5: Assault_Rifle [17:31] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [17:31] CGCSH Flood Marine NPC 2.5: Assault_Rifle [17:31] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [17:31] CGCSH Flood Marine NPC 2.5: Assault_Rifle [17:31] CGCS Halo Ground Meter 2.7 Listen: 1c852905-b8c0-5756-aa54-c14de4802d2b [17:31] CGCS Halo Ground Meter 2.7 Listen: 1c852905-b8c0-5756-aa54-c14de4802d2b [17:31] CGCS Halo Ground Meter 2.7 Listen: 1c852905-b8c0-5756-aa54-c14de4802d2b [17:31] CGCS Halo Ground Meter 2.7 Listen: 1c852905-b8c0-5756-aa54-c14de4802d2b [17:31] CGCS Halo Ground Meter 2.7 Listen: 1c852905-b8c0-5756-aa54-c14de4802d2b [17:31] CGCS Halo Ground Meter 2.7 Listen: 1c852905-b8c0-5756-aa54-c14de4802d2b
  13. Thank you for you help, I really appreciate it, I will tinker a bit more and post back what I find.
  14. NVM while loop broke it. So I have narrowed it down kind of, putting a delay in didn't solve the problem though, I have found that it is indeed doing either or, either it receives the message or sends one back. it can't do both.
  15. AH HA, i got it, if the first part of the script fires, the region say doesn't, it can't receive and send a message at the same time, it's doing either or. but why? alright i will try a larger delay.
  16. What the heck, out of 32 hits only 1 sent back the message, but then in another test I got 14 back .... what does it mean, did i find the iluminati in SL or something? oh i think i got it, it might be doing either OR! if it hits one meter it doesn't really the message back, here is the target this is what it takes to send the message back if (m == "Assault_Rifle") { integer chance = llRound(llFrand(100)); if(chance>=Assault_Rifle+Global) { hp -=llRound(llFrand(Assault_RifleD)+Assault_RifleMD); llSetText("HP:" + (string)hp + "\n" + HP + "\n " + Faction + "\n" + Ship + "\n" + Attacks , <1.000, 0.000, 0.000>,1); llRegionSayTo(id, -943, "Assault_Rifle"); llOwnerSay(id);
  17. here is my ray cast. list results = llCastRay(start, start+<range,0.0,0.0>*llGetCameraRot(),[RC_REJECT_TYPES,RC_REJECT_LAND,RC_DETECT_PHANTOM,FALSE,RC_DATA_FLAGS,RC_GET_ROOT_KEY,RC_MAX_HITS,1]); llSleep(0.03); key target = llList2Key(results,0); llTriggerSound(llList2String(llListRandomize(firesound,1),0),1.0); llRegionSayTo(target,gTargetChan, damage_type ); llResetOtherScript("bullet_"+(string)slave); llResetOtherScript("m_f"); //llOwnerSay("Jam % "+(string)jamchance);
  18. It seems super inconsistent, but it does at least seem to be, kind of working. here is a feed from it sending messages back and forth. okay this is very strange it seems it has to do with me moving or not, if im moving towards it it's more likely to pick up the message, what the heck. its getting the uuid, but only sometimes? [16:34] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCS Halo Ground Meter 2.7 Listen: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCS Halo Ground Meter 2.7 Listen: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCS Halo Ground Meter 2.7 Listen: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCS Halo Ground Meter 2.7 Listen: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b [16:34] CGCSH Flood Marine NPC 2.5: 1c852905-b8c0-5756-aa54-c14de4802d2b
  19. Yeah it only seems to be working about half the time, and then the script doesn't seem to send messages at all. OH I'm using this. if (CONTROL_ML_LBUTTON & ( held) && ammo_count > 0) the weapon works just fine, it seems to be only the return message that gets lost and only sometimes? and I can't reproduce or figure out why it does. some times the return message gets sent from the target object, and sometimes it just doesn't.
  20. Hm I will try that, I have run into a final problem that I can't seem to solve. my ray cast continues as long as the button is held down, and each time it "fires" it sends the message to the target object, that target object then sends back a message, but the problem I have run into is. the target object will continue to receive messages, but only returns the message, once and not each time it receives the message, is there a way to fix this?
  21. So I got the core of it working now thanks to your help, is it possible for it to make that message got to the object the avatar is sitting on?
  22. Thank you so much! this is exactly what i needed. I had no idea LSL saved the ID like that.
  23. I wasn't sure how to word the question but I can explain in more detail here. have two working objects, one is a cast ray that shoots a ray and then sends a message to the object it hits. the second object then takes that message and does stuff with that. is there a way I can make the second object, the one being hit, send a message BACK to the object that cast the ray? so it's a two way communication.
  24. OH this makes sense, thank you so much for the reply I will try that!
  25. And I will enjoy getting exactly what I pay for for the amount I pay for it.
×
×
  • Create New...