Jump to content

Darkie Minotaur

Resident
  • Posts

    1,663
  • Joined

  • Last visited

Everything posted by Darkie Minotaur

  1. I'm not sure, you posted in the right forum. If you are looking for a script or someone to write you a script, the Wanted forum or the Inworld Employment forum are the ones to look in. If you want to write the script, but don't know where to start, you are right here. What you need, if I understand you right, are dialogs - the wiki will explain how to use dialogs and give you some examples. Basically, you will make a first dialog with the first level choices: Food, Cleaning, Cooking .... Depending on the ava's choice, you will just open another dialog with the corresponding sub-choices. If you need more help, just give a shout.
  2. What you ask should be possible - and not even too complicated. However, this is a group for scripter (including beginners) discussing scripting issues - not a forum the request scripts. You can do so in the Wanted forum ot the Inworld Employment forum
  3. The sond doesn't have to be in the object if you use the UUID. If you put the script in the prim, you can as well use the name of the sound.
  4. integer on = TRUE;string sound = ""; //UUID or the name go heredefault{ touch_start(integer iNum) { if (!on) { llMessageLinked(LINK_SET, 0, "on", NULL_KEY); llLoopSound(sound, 1.0); } else { llMessageLinked(LINK_SET, 0, "off", NULL_KEY); llStopSound(); } on = !on; }}
  5. This forum is for discussing scripting issue - not for reqursting and supplying scripts. You better move your request to the Wanted or the Inworld Employment forums
  6. list glAvas;integer giCounter;default { touch_start(integer total_number) { if ( llDetectedKey(0) != llGetOwner() ) { glAvas += llDetectedName(total_number); ++giCounter; } else { llOwnerSay((string)giCounter + " avatars have clicked me since the last check."); llOwnerSay("Here are their names: " + llDumpList2String(glAvas, ", ")); giCounter = 0; glAvas = []; } } }
  7. Yes, that's right - the UUIDs of SL certainly won't work. If you look here, you'll find a manual how to make the textures. In the viewer menu you will find Upload Image - or something similar that let's you upload the texture.
  8. If you want to use that script, you just have to add a line: llSetPayPrice(PAY_HIDE, [gPrice,PAY_HIDE,PAY_HIDE,PAY_HIDE]); // Script Name: SINGLE_ITEM_ONE_PRIM_VENDOR_by_Wednesday_Grimm.lsl//SINGLE ITEM ONE PRIM VENDOR by Wednesday Grimm.lsl// Downloaded from : http://www.free-lsl-scripts.com/cgi/freescripts.plx?ID=1138// This program is free software; you can redistribute it and/or modify it.// Additional Licenes may apply that prevent you from selling this code// and these licenses may require you to publish any changes you make on request.//// There are literally thousands of hours of work in these scripts. Please respect// the creators wishes and follow their license requirements.//// Any License information included herein must be included in any script you give out or use.// Licenses are included in the script or comments by the original author, in which case// the authors license must be followed.// A GNU license, if attached by the author, means the original code must be FREE.// Modifications can be made and products sold with the scripts in them.// You cannot attach a license to make this GNU License// more or less restrictive. see http://www.gnu.org/copyleft/gpl.html// Creative Commons licenses apply to all scripts from the Second Life// wiki and script library and are Copyrighted by Linden Lab. See// http://creativecommons.org/licenses/// Please leave any author credits and headers intact in any script you use or publish.// If you don't like these restrictions, then don't use these scripts.//////////////////////// ORIGINAL AUTHORS CODE BEGINS ////////////////////////////////////////////// CATEGORY:Vendor// DESCRIPTIONINGLE ITEM ONE PRIM VENDOR by Wednesday Grimm.lsl// ARCHIVED BY:Ferd Frederix// vendor// Wednesday Grimm// June 10, 2003//// Simple vending script, gives correct change.//////////////////////////////////////////////////////////////////////////////////////////// HOW TO USE THIS SCRIPT By Jacqueline Bancroft////This is a vendor program for a single item. This is how it works:////You rez a cube and pretty it up.. maybe put a texture of what you're selling on the side.//Put the item that you want to sell into the cube you made.//Put this script inside the cube you made, and then open up the script to edit it.////Where it says gPrice, put the price of the item you want to sell after the equal sign.////Where it says itemName, put the item name of the item that you want to sell after the equal sign. Be very aware that the script is case sensitive, so make sure you spell it correctly. For example, "My Object" is different than "my object".////Where it says summary1 and summary 2, fill in a description of the item what you wish to sell. make sure that you surround the description with quotation marks, or else the script will go wonky. When a potential customer touches (clicks) on your box vendor, your box vendor will whisper summary1 and summary2 to them.////That's about it. Be sure to thank Wednesday if you use this script.//////////////////////////////////////////////////////////////////////////////////////////integer gPrice = 5; // cost of the item// name of the item in object's inventory, to vendstring itemName = "test_note";// two summary lines to describe the objectstring summary1 = "this is a test note, it tests this script";string summary2 = "it is very interesting. Cost is $5";// give the item to a customerdispense(key toWhom){ llGiveInventory(toWhom, itemName);}default{ state_entry() { // we need this permission to give change llRequestPermissions(llGetOwner(), PERMISSION_DEBIT); llSetPayPrice(PAY_HIDE, [gPrice,PAY_HIDE,PAY_HIDE,PAY_HIDE]); } touch_end(integer total_number) { // if someone touches object describe what's for sale llWhisper(0, summary1); llWhisper(0, summary2); } money(key id, integer amt) { if (amt >= gPrice) { // customer has given us at least enough money amt -= gPrice; dispense(id); } if (amt > 0) // give back change { llGiveMoney(id, amt); } }}
  9. It's a common problem: The permission is being asked on state_entry which only gets triggered when you reset your script or compile it (since you have no other state than default). So the HUD won't get permission of the new avatar because it never requests them. Since it is a HUD, do the opermission requesting in the attach event.
  10. Thank you, Innula - I think that I can mod it so it does what I want!
  11. The problem is, that jbandar uses the Avatar variable when showing the dialogs - and it is set to the owner key. Make your touch event: touch_start(integer s) { Avatar = llDetectedKey(0); llDialog(Avatar, "\n\nSelect a color group", main_menu, channel);}
  12. *snickers* that's exactly how I do it at the moment - but for several reasons it is better for my thinggie to calculate pos and rot. If I ever understand what Rolig did, that is
  13. Thanks a lot! I will have a look tomorrow.
  14. The offset of a child in the link set, I assumed, is it's local position - am I mistaken here?
  15. Thank you for your suggestions. @Dora: I followed Void's rotation tutorial "To rotate in the Self Frame (prim's own axis): (vRotAmount2ChangeBy * vRotCurrentLocal)"I tried it, too - the result wasn't any better @Rolig: I do reposition it - flap isn't rotated around the center of the flap.
  16. Rotations and me will never be friends. It's a simple task: I have an evelope - the body is the root, the flap is the child. On touching the envelope, I want the flap to open (to rotate up and reset the position, so it is still aligned to the envelope body) - somehow, I don't get to do it correctly. Here is what I have (the script is in the root): default { touch_end(integer num_detected) { rotation grIncrementX = llEuler2Rot(<160.0,0.0,0.0>*DEG_TO_RAD); list liposrot = llGetLinkPrimitiveParams(2, [PRIM_POS_LOCAL, PRIM_ROT_LOCAL]); rotation newrot = grIncrementX * llList2Rot(liposrot, 1); vector newOffset = llList2Vector(liposrot, 0) * grIncrementX; llSetLinkPrimitiveParams(2, [PRIM_POS_LOCAL, newOffset, PRIM_ROT_LOCAL, newrot]); } } Where do I go wrong (yet again)?
  17. Well, yes - if your database 'speaks' http, you can use llHTTPRequest - the wiki will explain how to use it.
  18. That depends, I guess, on your kind of DB server. LSL can basically use http (or https) as a means of communicating with the outside world. If your DB allows for direct http communcation, you can use that - but that is a question of which interfaces your db offers.
  19. What you usually do is, you make a php scrpt that connects a MySQL database.
  20. I wasn't snickering at you, Luc, though - I was snickering because I hadn't this very obvious and kind of funny point myself earlier.
  21. *snickers* You're right, Luc, replacing owner by avatar in the best case doesn't change anything - in the worst case, it will make the script cause errors on compiling it.
  22. It really is difficult to say why it doesn't work without knowing more than that it "doesn't work at all". Try to trace down where it fails (e.g. by adding some output that shows you, that a certain part of the code gets executed) and then paste at least this bit here.
  23. If you are completely new, you may want to look at some tutorials - you will find some here to get some LSL knowledge. As for server based systems, you can look at the script library - there is a section on server based systems. Last but not least - the wiki will be your best friend when scripting. Good luck and have fun!
×
×
  • Create New...