Jump to content

Darkie Minotaur

Resident
  • Posts

    1,663
  • Joined

  • Last visited

Everything posted by Darkie Minotaur

  1. Wow - a lot of testing and fiddling you did - that's good. The most obvious answer to your question is frustratingly simple string gsURL;default { touch_end(integer num_detected) { gsURL = llStringTrim(llGetObjectDesc(), STRING_TRIM); llLoadURL(llDetectedKey(0), "Your message goes here.", gsURL); }}
  2. You use PRIM_MEDIA_PERMS_CONTROL for that - but you can set thi right from the start via the edit menu
  3. That's what I would do - link a second prim for choosing the url and set it with llSetLinkMedia
  4. It's difficult to see where the problem is, without seeng the data that the PHP receives and which it tries to actually write to the db in the following line of the php $result=mysql_query($sql) or die(mysql_error()); Replace die(mysql_error()) by die($sql) and then run the script again and paste the error message again
  5. I see. In that case you send strange data from SL. If you're using the LSL script given in the other thread, try to make an llEscapeURL on the values - like this: string values = "Timestamp8601="+ llEscapeURL(llGetTimestamp()) +
  6. obvously it's the backshlashes in line 8 that causes the warnings $Timestamp = gmdate("Y-m-d\TH:i:s\Z",time()); I'm not really sure what they are supposed to do here - just try withopu the escaped sequences $Timestamp = gmdate("Y-m-d H:i:s",time());
  7. What I do as yet not fully understand is this: If a rp member doesn't have a 'valid' Hall Pass, what would happen? If the Hall Pass is a token that has to be worn visibly, it could simply detach itself. Even it it isn't ruinning in the inventory, it should keep its state. so, when you give out the Hall Pass you could calculate and store experation time in a variable. As long as the owner wears it, the thinggie will regularly check of the experation time has been reched. If so, it will detach on every attempt to attach it again. This way, is couldn't be worn again. If there's other stuff you want to do, you should store the tokens' data centrally in some kind of server.
  8. I'm not sure what the problem is - but basically, the sensors won't return the number of scripts and/or objects. Make sure you understand what the parameters in question will tell you - check here for objects and here for scripted. Apart from that: to get the totals, you don't need the loop - detected gives you the total for each sensor it's a bit strange that you should say the results in the tiuch event and not in the sensoe event leave a little time between the 2 sensor calls - use a timer to do so a sensor call will give you up to 16 results - if there are more objects/agents, you won't get them
  9. I have the same problems from time to time. I suspect, in many cases the asset server plays up - in other, my sim needed a restart.
  10. If your HUD is an object that consists of several prims, that each should play a different animation, then you detect which prim has been touched by using the llDetectedLinkNumber function inside the touch event to find out which prim has been touched. You put the desribed script in the root. It could still be tricky to associate link numbers to animatios. So if you want to go down this road, let us know. If your HUD consists of one prim and you want to associate certain areas of the prim to certain animations, you could find out with the function llDetectedTouchST in the touch event, which area of the prim has been touched. If your HUD consists of one prim or the touch to a certain prim triggers a dialog, that you use to choose an animation from, the script I described plus the alterntions for the HUD use case is a simple example how to do it. Put the script in the prim that you want to make the dialog come up on touch
  11. Ah - ok - that doesn't change too much, really. You don't need step 1 instead of the changed event, you use the attach event in step 2
  12. Let's start with the menu. First, you inact have to decide if you want a dialog or if you want a HUD - the two ways differ a lot - thecnically and in the use cases they are best used for. If you are talking about the poses (which are animations) for e.g. for some sitting obect, a menu would be best. If you want to play animations everywhere you are - like gestures - a HUD wold be better. In ths case, the HUD could open a dialog for choosing the animation (and whateer you want to do - like producing particles. So let's start with a menu - the basic flow is: You touch something Dialog comes up you press on of the 12 possible buttons the script pplay an animation First of all, the LSL wiki is the scripter's best friend. How to use a dialog, you can read there. I won't go into the dialog and it's workings any deeper - the wiki page should help you with that. For the playing the animations, the most tricky bit (though not really tricky) is that the script has to get the permision to play animations on your avatar, first. Assuming is's somer sitting object, the flow above could look like this in a more detailed ersion: Ava sits on the object - you should define a sit target for it the object receives an changed event - to be more exact, a change in the links - the examples in the wiki pages show how to work with this kind of change event Now you call the llRequestPermissions function for playing an animation - that would finish the first step in the script Now you define what to do on a tiouch by adding a touch event. On receiving the event you check if the permision to play animations using llGetPermissions - that would look something like: touch_end(integer num_detected) { integer perm = llGetPermissions(); if (perm & PERMISSION_TRIGGER_ANIMATION) { //open dialog }} now you open the dialog and wait for input - apart from calling llDialog, this will involve listening to the response, which you will need to creat a listener for with llListen and a listen event in the listen event, you play the chosen animation using llStartAnimation You're there! Of course you can come back anytime one of these steps causes you headaches.
  13. I'm honoured but can't really add anything to what Peter has already said. But then again, it's no surprise that I can't anything beyond Peter's wisdom!
  14. Not that I know off - many scripts use other ports - e.g. most shout cast serer listen to 8080
  15. You'd have to be a little more specific as to what you want to do. In theory, there are quite a few ways to go through a proxy, natting .... - but if that is an option, depends on what you want to do and which ports your ISP blocks.
  16. Für mich kann ich nur sagen: Mein Profil ist hinsichtlich meiner Idendität deutlich anonymer als mein E-Mail-Adresse - und das dürfte bei den meisten so sein
  17. I would leave the soundname test in integer on = FALSE;string soundname = "soundname"; //put sound file name heredefault{ state_entry() { on = FALSE; soundname = llGetInventoryName(INVENTORY_SOUND, 0); } touch_start(integer total_number) { if(soundname != "") { if(on) llStopSound(); else llLoopSound(soundname, 1); on = !on; } }}
  18. That's to be expected - it says in the wiki that it only works if the "... avatar key, present in or otherwise known to the sim in which the script is running"
  19. I'm not sure I fuly understand your problem - here are a few things that you could mean: You have a list of avas - for each ava, you want a button on the dialog. So the first problem would be the length of te names. You could number your buttons according to the position in the list. In order to know which button correspond to which name, you could use message on the dialog. How to send another ava a dialog? Since you have a list of keys, just get the right one and dend it. Mind, that the avas have to be in the same region to send them a dialog (and for llKey2Name work reliably). Here is simple example to illustrate what I've described above list glAvas;integer giChan = - 12345;integer giListener;default { state_entry() { } touch_end(integer num) { integer index; list buttons; string msg; for (; index < llGetListLength(glAvas); index ++) { buttons += (string)index; msg += (string)index + " - " + llKey2Name(llList2Key(glAvas, index) + "\n"); } giListener = llListen(giChan, "", llDetectedKey(num), ""); llDialog(llDetectedKey(num), msg, buttons, giChan); } listen(integer channel, string name, key id, string message) { llListenRemove(giListener); giListener = llListen(giChan, "", llList2Key(glAvas, (integer)message), ""); llDialog(llList2Key(glAvas, (integer)message), "whatever message", ["which", "buttons ever"], giChan); }} ETA: This is only a simple example - e.g. it assumes the list of avas is not longer than 12.
  20. You could store and retrieve whatever you have in the nc out-world and get it from there - with as many Fort Knox meassures as you deem necessary.
  21. Replace the http_response event with this one: http_response(key id, integer status, list metadata, string body) { body = llDeleteSubString( body, llSubStringIndex( body, "<!-- www.000webhost.com Analytics Code -->" ), -1 ); if((id != put_id) && (id != get_id) && (id != del_id)) return; if(status != 200) { llOwnerSay("CANNOT CONNECT TO SERVER"); return; } // And spit out the information we got. list slurl = llParseStringKeepNulls(body, ["/"], []); slurl = llListReplaceList(slurl, [llEscapeURL(llList2String(slurl, 4))], 4, 4); llOwnerSay(llDumpList2String(slurl, "/")); } That should do the trick. Btw.: I followed the wisdom of the two ladies
  22. It works because the region name you took doesn't have other characters that get escaped besides the blank. I don't know it other charracters that get escaped are allowed in region names.
  23. What Rolig says is part of the truth - but, alas, SL is a bit trickier. If you have done all the URL escaping and unescaping on lets say http://maps.secondlife.com/secondlife/Dreamworld Pirate/143/221/800 you will get this back correctly. If you say that, you will get a link like Dreamworld (143, 221, 800) - just part of the name and the coordinates are not part of the link. That is because URL do not like spaces. You should think, doing an llEscapeURL would help, but it doesn't - the SLURL to work just wants the blank spaces to be escaped by %20. So in the example, http://maps.secondlife.com/secondlife/Dreamworld%20Pirate/143/221/800 would get you the right link
×
×
  • Create New...