Jump to content

BEGOCER Lehmann

Resident
  • Posts

    29
  • Joined

  • Last visited

Everything posted by BEGOCER Lehmann

  1. CmpZ You are my savior! It works perfectly after I incorporated it into the vehicle! I was up till like 4am last night just fuming at the script!
  2. Oh snap its ya boy back at it again with a probably easy fix to a problem that is causing him a ton of issues. I have yet another vehicle script (how original) that has voice commands on it as it has guest/owner modes. I've got a combat system installed and working and that is where the two voice commands that use channel 0 to turn the system on and off. However the script listens to all avatars, not just the seated one. I've got in my state_entry this: state_entry() { sitting = llAvatarOnSitTarget(); llListen(0,"",sitting,""); then in my listen area this: listen(integer c,string n,key i,string msg) { if(msg == "cs on") { cson(); } Technically shouldn't that listen to just the person sitting? Not everyone? As what I've googled up across the forums here llListen(0,"",llGetOwner()""); just listens to the owner, as it should. I've tried adding things like if(sitting == sitting) from other scripts I've found and nothings worked yet (Imagine a fly bumping into a window trying to get out despite the window being open next to it- thats me and how I look when I script. I've probably overlooked so much correct stuff) And I'm probably forgetting something in my script like grabbing keys or something... I really have no idea how this stuff works after all these years still lol. Once more I come to the forums for help!
  3. Ok! I got it working! Oh man you guys saved me so many hours of screaming and swearing! Changed the "experience_permissions(key target_id)" to "run_time_permissions(integer target_id)" and changed the RequestExperiencePermissions to llRequestPermissions(llDetectedKey(n), PERMISSION_ATTACH); and that made it work! I appreciate it!
  4. Sorry for the long response time. Gonna check that post out now!
  5. Currently I'm using AttachTAttachToAvatarTemp. For turret positions it's just for a vehicle with one turret. (Driver + gunner). I've seen it been done before where I've sat on other people's combat vehicles and it asks to attach HUD that lets me toggle settings and what not.
  6. Oh boy here I go again getting lost/confused/angry at something that is probably simple to do but I have no idea what to do. So I've got a HUD that will be able to control a turret on a vehicle that has to be worn for it to 'fire' the turret. I'm using a HUD as opposed to having fire controls in the turret itself using key commands as that method just totally messes up my vehicle's driving scripts despite not being in the same prim for some reason... I've got everything working up to a certain point- firing controls, the turret will rez the HUD on sit and that HUD will then request to be attached to owner only then detach on stand etc. But what I cannot figure out is how to make the turret when sat on rez the control prim and attach to ONLY the user of the turret rather than owner only (which it is currently at the moment as I'm using some open source script). I'm not sure how to make the rezzer spawn the control HUD with the right request attach lines and know to attach to the seated user. WHAT DO!?
  7. Though the weird thing is that the physics is showing its all there but its reacting like its a convex physics shape type when its definitely set to a prim shape...
  8. Hey thanks for the help! So I'll post a pic of my upload window and what is happening in it. For uploading, I always click the Analyze button as I've had other physics shapes go wonky if I didn't. Here's the .blend file with the physics shape I'm trying to get to work. https://pasteall.org/blend/e4ebce5db836492293b771ac866caa2e Now this is right after I calculate the fees and what not. ...and this is using the official SL viewer. I've never gotten this result on Firestorm lol This is the lowest physical number I've gotten in any of for just the physics shapes....man lol But alas when I link it to my ship it goes from a 180LI to a 327LI The only other things that have physics shapes are two landing gear struts and a front landing gear wheel, all with super basic physics shapes. And when I set their physics shapes to none the LI doesn't jump from the 180LI when physical. I should try to reupload them in the official SL viewer since I got this result....
  9. So I'm feeling pretty noobish right now. I've got an issue with a physics shape I'm working on for a ship, but its being a right piece of work when it comes to uploading it. I made it super low detail, just enough to encircle the ship and give it basic interior walking space, but whenever its uploaded and set to prim physics shape it goes from the calculated 4LI when physical to 160+LI... Now it is long, about 30M but I've seen ships larger than this with their own, much more detailed physics shape have nearly a quarter of the LI of what I'm getting with mine. I've checked 2309572039 times that there are no small faces in the .dae file that would cause it to flip out, but nothing is coming up or even appearing to be wrong. Also I noticed when I view the physics shape in Firestorm the opposite sides of the exterior faces are calculated on the inside as well, which is something that is definitely not needed...I don't know what I'm doing wrong. I've uploaded about 30 (seriously) different tests and they all result in the same issue. I uploaded the shape with the custom physics shape of the actual model shown here as a tester too This pic is in the tail end, where it should've only had that small walkway as a shape you can interact with. What on earth am i doing wrong...?
  10. So I resolved the issue. Lesson I learned: Firestorm bloody sucks for uploading mesh. Installed the normal viewer and bam! The Method options and etc actually work and the physics are fine when uploaded. I gotta stop just relying on 1 freaking viewer...
  11. So I've been having this issue for quite a while. The quick run down is that I have a block I'm needing to use as a physics barrier for a vehicle I'm making. The truck rides on suspension struts and needs a physics shape that 'follows' so the vehicle can climb over stuff and won't end up hovering due to a physics bock that doesn't match its suspension shape. Basically this is how I want the end result to be, just like the un-analyzed shape.  But that doesn't work in world as it reacts how it would be as if its analyzed. See below for the analyzed shape:  The hollow areas I want to remain open for phsyical interaction are now closed over with and no settings allow me to change that. I literally have no idea and past experiments of multiple uploads of the same mesh with custom physics have each given different results. Any suggestions (or in proven past instances, any obvious reasons that I haven't taken into accordance?)
  12. So far I haven't seen any loops or anything but I had a line to check the memory and it had none left when it gave me the error.
  13. Great news: I got it working to how I wanted it. Turns out a script I have had the lines about making something move by prim name in it all along.... Damn you life for stressing me out... So the scripts in top notch working order (probably can be refined but at the moment I don't care) but the only issue is that I have too much in it and it's giving a stack heap error lol No biggie as I can halve it into 2 scripts that will resolve the issue. Thanks again Rolig/Everyone who helped me with my irritating questions!!
  14. I literally have no freaking idea what to do. I've been trying for a week straight! I thought I had a breakthrough last night but it fell flat as the ways I tried only changed the name of the root prim so the idea failed. I have no idea how to make this script identify a prim (and others due to the different parts that need to move) in a link set and have the prims move when a command (that isn't the link's name) is given.
  15. Lol It's a definite conundrum. It bugs me that Scripting sticks with me after I log off as it's the thing I'm least talented in SL
  16. Oh yeah. It's slowly coming. Just got a full palette right now. College...moving to a new home...massive travelling for college and job... the usual lol
  17. I only realised just now that what I'm trying to hasn't even been implemented into this thing....only the prim identification has been seen to... I need it to actually listen to a command (say "attachhood") and any prim named "hood" will move to a set point laid out in the llSetLinkParamsFast area.... Eh... I'll figure it out
  18. state_entry() { llListen(931, "", NULL_KEY, ""); } listen(integer channel, string name, key id, string msg ) { if (llGetOwnerKey(id) != llGetOwner()) { return; } if (msg=="Anyone") //This part is received by a dialog script (controls permissions of vehicle operation; in this case the anyone option allows anyone to drive) { llMessageLinked(LINK_SET, 0, "anyone", NULL_KEY);//Sends a message to the link set which tells the vehicle script to change permissions from owner to anyone. I chose this one at random from the actual script. }
  19. Because I am a talentless, sleep deprived person who totally didn't realise the script was off... lol I've removed that repeated one and (most importantly!) turn on the script.... rofl Thanks for all the help everyone
  20. Oh crap yeah... thats what I get for cut and pasting from an old script....I'll change that Edit: LINK_SET makes nothing move at all. So I use the drop down dialog menu for the commands as well, so the below lines are from it. I have had no issues with this area as of yet: state_entry() { llListen(931, "", NULL_KEY, ""); } listen(integer channel, string name, key id, string msg ) { if (llGetOwnerKey(id) != llGetOwner()) { return; } if (msg=="Anyone") { llMessageLinked(LINK_SET, 0, "anyone", NULL_KEY); }
  21. Alright so I fixed up the script, got it working exactly to how it was needed! I also got it so if it ID's sepately named objects it'll only move the one that was specified. However.... I modified it to be commanded by link_message rather than listen. The first line that would command, say an objected named 'object 1' works, whilst the following grouping to control another object named 'object 2' does not. I have a feeling its because the link_message line has different content to the listen parameters, I just don't understand why it stopped working when the old version was set up to do almost the same thing (using link_message without the name identifying) and still worked. state_entry(){ key owner = llGetOwner(); llListen(931,"",owner,"");}link_message(integer chan,integer num,string msg,key id){ integer prim = check_for_prim(msg); // THIS is the link number you want if (prim) { if (msg=="object1") { llOwnerSay("found a linked prim named \"" + msg + "\""); llSetLinkPrimitiveParamsFast(0,[PRIM_LINK_TARGET, prim,PRIM_POS_LOCAL,<2,3,4>,PRIM_SIZE,<.5,.5,.5> ]);//used to store the part, just a placeholder part and x,y,x } integer prim = check_for_prim(msg); if (prim) { if (msg=="object2") { llOwnerSay("found a linked prim named \"" + msg + "\""); llSetLinkPrimitiveParamsFast(0,[PRIM_LINK_TARGET, prim,PRIM_POS_LOCAL,<1,12,12>,PRIM_SIZE,<.2,.2,.2> ]);//used to store the part, just a placeholder part and x,y,x }} else { llOwnerSay("this object does not have any linked prims named \"" + msg + "\""); }}}} Woo I used the insert code option!
  22. Ooh I see! I'll give it a whirl when I can log in next... RL is being a bugger right now... And yeah it looks better in world than my cut and paste here... I dunno how fancily post the scripts like you did lol. Thanks again Rolig!
  23. I've got another question about the wonderful cluster of numbers we call 'scripting' I have a truck which has quite a few customization options that can be drawn up or "removed"- basically the parts shrink down to the smallest size at a set point in the link set. Currently it works exactly how I want it to but I've been updating the mesh models, unlinking and relinking which changes the link numbers way too much for my liking. I'm wanting to make the script use prim names rather than link numbers which would allow for easier swapping of old parts and allow me to sell the truck mod, which currently its not due to it literally imploding if you link a new prim onto it. I have a basic script that can detect a prims name but when I put the very same llSetLinkPrimitiveParamsFast command in that would change a part of the truck, the script bugs out and tells me its "looking for an integer but a string" is given or something along those lines. I don't know why it would do that as it should just move the prim as its command to move is right after the area that says it found a prim with the desired name. The script itself is something I found in the forums here a while ago but it works almost to what I need. This is all just because I'm horrible with scripting and the way I have the llSetLink params is probably so wrong I'd make professional scripters cry in fear at my awful work. Currently the command for parts to move is given by a linked message which still works if I mix it into this script below: integer check_for_prim(string name) { integer i = llGetNumberOfPrims(); for (; i >= 0; --i) { if (llGetLinkName(i) == name) { return TRUE; } } return FALSE; } default { state_entry() { llListen(0, "", llGetOwner(), ""); } listen(integer chan, string obj, key id, string msg) { if (check_for_prim(msg)) { llOwnerSay("found a linked prim named \"" + msg + "\""); llSetLinkPrimitiveParamsFast(0,[PRIM_LINK_TARGET, msg,PRIM_POS_LOCAL,<0,0,-1>,PRIM_SIZE,<0,0,0> ]);//used to store the part, just a placeholder part and x,y,x } else { llOwnerSay("this object does not have any linked prims named \"" + msg + "\""); } } }
  24. I wish I could do that but it'd drive me nuts seeing the turret lag behind a bit, plus the vehicle is set up to be a bit bouncy and be prone to flipping. Plus border crossing D:
  25. I'll give it an attempt when I'm on next. Thanks for all the help! I posted below just an info update that the gunner/truck scripts are separate but the truck one is technically made by me so in terms of repairing and improving... it needs lots....
×
×
  • Create New...