Notecard Reading
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
08-27-2008 13:06
Hello again all working on this time a notecard reader and hit a road block im using the basic template from the wiki to read the notecard and i got i left it to llSay into chat the lines its read it starts on line 3 to read as i left // comments in the card im creating a basic reader and will use it for future reference in products i script but i hit a road block in the notecard i want to define the contents to be read like this http://scfire-dll-aa04.stream.aol.com:80/stream/1040, .977 80's Channel minus the URL auto brackets the forum posts grr but im road blocked as i am stuck i have searched forum on the way to hook the specific data but with peoples scripts & examples being more then just a bare bones im wondering if some nice person could show me the correct place and the right hooks on the basic reader i post below  so i can tell the script that i want this data stored into seperate sections for example the URL to be one thing it will specifically read and the name the last specific thing to be read with the comma being ignored in the equation i hope that makes sense lol. or If at all just the URL and the comma and name ignored as its mostly there for reference im getting better with llDialog so hopefully if i can get a notecard reader working i can expand on my llDialog menu driven products alot more  im not massivly advanced i learn mostly from scripting by editing and wiki usage but im a little lost when it comes to Note reading and telling the script what data specifically i want from the note card  but on the whole i understand from most peoples look at only examples gets confusing to what i need to  so rather then me keep being confused better to ask if some one can show me the specific information on the example thank you to any one who is kind enough to help me  key gQuery;
integer gLine = 3;
string gNoteCardName = "_Stations";
default { state_entry() { llSay(0, "Reading notecard..."); gQuery = llGetNotecardLine("gNoteCardName", gLine); } dataserver(key query_id, string data) { if (query_id == gQuery) { if (data == EOF) { llSay(0, "No more lines in notecard, read " + (string)gLine + " lines."); } else { llSay(0, "Line " + (string)gLine + ": " + data); gLine++; gQuery = llGetNotecardLine("gNoteCardName", gLine); } } }
changed(integer change) { if(change & CHANGED_INVENTORY) { llResetScript(); } } }
EDIT forgot to put gLine = 3; lol
|
|
Haravikk Mistral
Registered User
Join date: 8 Oct 2005
Posts: 2,482
|
08-27-2008 14:39
What you want in this case sounds like llSubStringIndex(). Basically, once you have the line you want, you do this: dataserver(key query_id, string data) { if (query_id == gQuery) { if (data == EOF) { llSay(0, "No more lines in notecard, read " + (string)gLine + " lines."); } else { integer comma = llSubStringIndex(data, ","); if (comma > 0) { string url = llGetSubString(data, 0, comma - 1); string name = llGetSubString(data, comma + 1, -1);
llSay("Found URL: "+url); llSay("Name: "+name); } // Probably an invalid line, ignore it } } }
This will look for lines with a comma on them, take everything before the comma and interpret it as a URL, and everything afterwards as the name/description/whatever.
_____________________
Computer (Mac Pro): 2 x Quad Core 3.2ghz Xeon 10gb DDR2 800mhz FB-DIMMS 4 x 750gb, 32mb cache hard-drives (RAID-0/striped) NVidia GeForce 8800GT (512mb)
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
08-28-2008 01:26
Thank you for the pointer was very helpfull i believe i got the basics understood but will take me some time to get the script working and doing as i intend with other functions 
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
08-28-2008 08:17
ok i rechecked the the wiki's and such and found on notecard lines and the basic reader that will output the read lines as i posted previous now im unclear on how to tell this command set that you posted how to read the specific line i want to output just for debugging purposes just so i know its picking up the line and seperating the URL and the Description so i can call them with another set of commands if you or any one else could help me a little more with how to tell the posted below help i had previous so i can pick out specific line would be great  i understand how to do the substrings but im missing the line i want to pick up from the notecard lol in this case line 3 or 4 or 5 ETC integer hyphen = llSubStringIndex(data, "|"); if (hyphen > 0) { string url = llGetSubString(data, 0, hyphen - 1); string name = llGetSubString(data, hyphen + 1, -1); llSay(0,"URL: "+gUrl); llSay(0,"Description: "+gDesc);
EDITED a few things to make myself clearer additionally i changed a few bits on what you posted to match the format im trying to get in my script 
|
|
Very Keynes
LSL is a Virus
Join date: 6 May 2006
Posts: 484
|
08-28-2008 12:52
In your example you are only displaying lines that contain the "|" symbol so if lines 3 or 4 or 5 ETC do not contain it, they will be read but not displayed. Try Moving your debug code outside the if statement i.e. after the closing } like this
integer hyphen = llSubStringIndex(data, "|"); if (hyphen > 0) { string url = llGetSubString(data, 0, hyphen - 1); string name = llGetSubString(data, hyphen + 1, -1); llSay(0,"URL: "+gUrl); } llSay(0,"Description: "+gDesc);
Although I have no idea what gDesc represents as you posted a very incomplete code snippet. The best way to get help is not to assume you know which block the error is in and then not show how the data is getting into the function. Rather post full scripts or at lest the assignment portions along with the sub function.
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
08-28-2008 14:51
My apologise forgot to repost the full code im still having problems i can get the script to say description and URL but i cant get it to spit the actual URL and description seperate i will post the full script up in a bid to debug the current problems i think i got the substring indexs in the wrong place or im missing some other code
key kQuery;
integer iLine = 3;
string iNoteCardName = "_Stations";
string gUrl;
string gDesc;
default { state_entry() { //llSay(0, "Reading notecard..."); kQuery = llGetNotecardLine(iNoteCardName, iLine); } dataserver(key query_id, string data) { if (query_id == kQuery) { if (data == EOF) { //llSay(0, "No more lines in notecard, read " + (string)iLine + " lines."); } else { integer hyphen = llSubStringIndex(data, "|"); if (hyphen > 0) { string gUrl = llGetSubString(data, 0, hyphen - 1); string gDesc = llGetSubString(data, hyphen + 1, -1); //llSay(0, "Line " + (string)iLine + ": " + data); iLine++; kQuery = llGetNotecardLine(iNoteCardName, iLine); } llSay(0,"Description: "+gDesc); llSay(0,"URL: "+gUrl); } { } } }
changed(integer change) { if (change & CHANGED_INVENTORY) { llResetScript(); } } }
gUrl & gDesc is what im trying to get the substrings to say before the | is the gUrl and after | is the description of the station trying to get this work to attempt to make a parcel media changer but as i said before the code i think i got the substring coding in the wrong place as all the debug lines is doing for me right now is reading all the URL's in the card in this case all of one and says [14:47] Object: Description: [14:47] Object: URL: but minue the information im trying to get  the standard notecard reader llSay i commented out to cut the spam down when as it was annoying lol EDIT lol as i post this i got it to work dont know what i did but now it says the URL and the description seperate now all i need is to sort out how to call one specific line at a time to make it possible for example i want line 3 with its URL and description so i can then select the gUrl for the parcel media settings iLine = 3 usually set to 0 but i got // comments in the notecard so i set it to 3 to ignore line 0 1 2 and go straight to the important info which in this case is a notecard with a few URL's now i got the thing to work properly 
|
|
Ron Khondji
Entirely unlike.
Join date: 6 Jan 2007
Posts: 224
|
Conflicting declarations
08-28-2008 22:08
You declare gDesc and gUrl twice. Remove the string declarations in the dataserver event and it should work.
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
08-28-2008 23:40
yes was declared twice but it did work without any errors so it being declared twice was actually causing it to work anyway i found on the test script i found in my inventory i had missed the { after the if statement to seperate the | and with correcting the one in the prim it then spat out the debug info I have since last night cleaned up the stray declarations and got them globally just easier for me to work it that way hehe  Partly my fault as i didnt comment where the debugs or the seperater were im not massivly good with commenting scripts  i have taken your suggestion however and moved the coding outside of the Dataserver event so it cant cause any problems hehe  EDIT Whoops mis info
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-13-2008 01:44
after some much appreciated help i got a single notecard reader working and fishing out the info i was looking for but the wiki example of a multicard reader has me totally poked in the eye.
what im trying to do is add another notecard reader to the single script i got so i can add a toggle menu button for private listed names using llKey2Name from names in the notecard if thats possible or a public mode that will allow any one to click the radio but im having huge troubles understanding the way the wiki advanced note reader is set out its just alien and im having problems figuring it out
if any one can help me with understanding a dual note reader other than the wiki's would be appreciated lol
|
|
Pale Spectre
Registered User
Join date: 2 Sep 2005
Posts: 586
|
09-13-2008 02:22
The secret to reading more than one notecard is in the query_id. So, using the code previously posted... state_entry() { kQuery1 = llGetNotecardLine(iNoteCardName1, iLine1); kQuery2 = llGetNotecardLine(iNoteCardName2, iLine2); } dataserver(key query_id, string data) { if (query_id == kQuery1) { if (data == EOF) { llOwnerSay("No more lines in notecard 1, read " + (string)iLine1 + " lines."  ; } else { iLine1++; kQuery1 = llGetNotecardLine(iNoteCardName1, iLine1); } } else if (query_id == kQuery2) { if (data == EOF) { llOwnerSay("No more lines in notecard 2, read " + (string)iLine2 + " lines."  ; } else { iLine2++; kQuery2 = llGetNotecardLine(iNoteCardName2, iLine2); } } ...I hope that's enough to give you the basic idea. 
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-13-2008 03:35
aaaaha! thank you so much for that i get the idea now and i will adapt my script to incorporoate it 
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-13-2008 04:53
hmmm ok now i not sure if i have the { } in the right places i will post the state_entry down to the end of the data server if you could possibly check it to make sure i got this right because im getting spammed with me trying to put the { } in the right places with testing the outputs lol it either spams or it doesnt give any information  the first part of the data server where its reading the card for the stations lists is working fine the problem is after that in the second card reading i think.
string iNoteCardName = "_Stations"; string aNoteCardName = "_Access";
default { state_entry() { kQuery1 = llGetNotecardLine(iNoteCardName, iLine1); kQuery2 = llGetNotecardLine(aNoteCardName, iLine2); if (aNoteCardName != "") { llSay(0, "Reading Access List"); } else llSetText("Missing _Access Notecard In My Inventory!", <1,1,0>, 1.0);
if (iNoteCardName != "") { llSetText("Loading Notecard Please Wait....", <1,0,0>, 1.0); llMessageLinked(LINK_SET, 0, "Loading..",NULL_KEY); } else llSetText("Missing _Stations Notecard In My Inventory!", <1.0,1.0,0>, 1.0); }
dataserver(key query_id, string data) { if (query_id == kQuery1) { if (data != EOF) { if (llGetSubString(data,0,1) != "//") { integer Seperater = llSubStringIndex(data, "|"); if (Seperater > 0) { Url += [llStringTrim(llGetSubString(data, 0, Seperater - 1),STRING_TRIM)]; Desc += [llStringTrim(llGetSubString(data, Seperater + 1, -1),STRING_TRIM)]; } } else iSkip1++; iLine1++; kQuery1= llGetNotecardLine(iNoteCardName, iLine1); } else { llSetText("Finished" +"\n" + (string)(iLine1 - iSkip1) +" " +"Stations Loaded", <0,1,0>, 1.0); llMessageLinked(LINK_SET, 0, "Finished!", NULL_KEY); llSleep(2.0); num_items = llGetListLength(Desc); num_pages = num_items / 9; if ((num_items - (num_pages * 9))>0) num_pages++; llSetText("Radio Ready Click Me To Open Menu", <0,0.5,1> , 1.0); llMessageLinked(LINK_SET, 0, "Ready" +"\n" + "Click Me For Menu", NULL_KEY); } } else if (query_id == kQuery2) { if (data == EOF) { if (llGetSubString(data,0,1) != "//") { llSay(0,data); } else iSkip2++; iLine2++; kQuery2 = llGetNotecardLine(aNoteCardName, iLine2); } else llSay(0,"Finished Reading Access List"); } }
Please ignore the linked messages and the URL seperators for now there all part of the larger script and the num_items and pages is part of the first cards dialog menu based on the info read in this case a radio and also please ignore the hover texts in there also there also part of the larger radio but its the dataserver and getting dual cards read that is the main bug or mess up that i done  also in the _access notecard i want the names to be read for aexample Jodie Suisei but i dont know how to tell the second data server how to hook that info and store it in my list Access; that i have defind globally if some one can help with that also  iSkip and its little friend is part of the skipped lines in this case the if (llGetSubString(data,0,1) != "//"  so it will ignore comments in the card
|
|
Pale Spectre
Registered User
Join date: 2 Sep 2005
Posts: 586
|
09-13-2008 07:25
// [snip lots of lines] else if (query_id == kQuery2) { if (data == EOF) // <===== should be: != { if (llGetSubString(data,0,1) != "//") { llSay(0,data); } else // <==== dunno what this does; probably nothing ;) iSkip2++; iLine2++; kQuery2 = llGetNotecardLine(aNoteCardName, iLine2); } else llSay(0,"Finished Reading Access List"); }
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-13-2008 08:30
doh! thank you pale after all that it was a simple thing missing lol *feels like a stupid girl and runs off and hides behind the scripting prim  * EDIT ok the only problem left now is the second Dataserver event in there doe say the name on the list now and ignores the // but it doesnt reach the else llSay(0,""  ; at the end of it so let me know when its finished reading the card  Double Edit Ok fixed it i managed to mess up a couple of {} lol
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-13-2008 09:42
Ok now i have my second notecard with just names in just my name in there right now for testing lol Jodie Suisei now can any body fill in me to how to hook this specific information from the second data server section below and put that information into my list which is access list Access;
string iNoteCardName2 = "_Access";
// [snip lots of lines] else if (query_id == kQuery2) { if (data != EOF) { if (llGetSubString(data,0,1) != "//") { Access = llParseString2List(data, [""], [" "]); llSay(0, (string)Access); } iSkip2++;
iLine2++;
kQuery2 = llGetNotecardLine(iNoteCardName2, iLine2); } }
Also if it is possible for a second script to control that access list? in the end i want to put a toggle into the sub options menu that i have created to handle all the options systems in this case is a few nice little additions and an Updater system in it. so i want to have the second script handle the the Access list and then send that info back to the note reading script and then link that into the touch event handler so if people are on the list to allow them if in private mode or let any one touch away if in public? EDIT ok so i managed to find the missing link so now when it reads the card it says the name thats on the list access  will keep dabbling around untill i get i find the right combo for the touch event  or would llParseStringKeepNulls() be a better choice? since im dealing with names and such and will need to call on that for the access control?
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-13-2008 12:07
Ok so i had a go with trying to get the touch event to trigger on my list but i think im missing some info for it to work right now all i get is the thing telling me im not on the list but i think it just needs a bit of a tweak if some one can help  touch_start(integer total_number) { avatar = llKey2Name(llDetectedKey(0)); integer i; if (avatar == llDetectedKey(0)) { i = llListFindList(Access. ); show_dialog(); }
else { llSay(0, "Sorry You Are Not On My Access List" ; } }
i have a feeling im on the right lines but im missing something any one can help ? 
|
|
Pale Spectre
Registered User
Join date: 2 Sep 2005
Posts: 586
|
09-13-2008 13:59
Checking for the string Avatar in the list Access...
if (llListFindList(Access, [Avatar]) != -1) { show_dialog(); }
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-13-2008 14:55
ooof i must not be following things properly i just cant get the access list to work with the touch event  Edit ok for the purpose of bug whacking here is the data server event for the info to push the card into my List of Access // Chopped Off Lines from the first dataserver card reading else if(query_id == kQuery2) { if (data != EOF) { if (llGetSubString(data,0,1) != "//") { Access = llParseString2List(data, [""], [" "]); } iSkip2++; iLine2++; kQuery2 = llGetNotecardLine(iNoteCardName2, iLine2); } } }
and here is my now touch event that wont trigger the access list as i seem to be doing something wrong and i think i may have missed something either in the data server eevent or some other processing  the posted below is what the touch event looks like when in anybody come click me and mess with my menu mode touch_start(integer total_number) { avatar = llDetectedKey(0); // detect user key then give them the dialog page = 0; // part of the dialog pages show_dialog(); // the dialog opener }
and here is my Notecard Layout
//comments up in these lines //more comments //some more comments Jodie Suisei
he only space in the name is between the first and last name now i have defined on a global
key avatar; // globally defined
avatar = llDetectedKey(0); // handled currently in the touch event
and i got all the information so far from peoples help and wiki rummaging but i dont seem to be able to peice the jigsaw togather very well im not overly great at puzzles lol now i know my name that is in the card is hitting the list Access; because the output using llSay(0, (string)Access); gives me Jodie Suisei printed into chat so i know that bit is working or isnt it perhaps? now pale i did follow what you posted up but im a might confused on how to fit it into my touch event tried a few different things and all of them wielded the else statement only triggering and the access denied message i put on it or if i was really lucky with messing it up i got no message at all from the else statement the only time i can get the dialog open is if i leave it on anybody come click me mode of anyone's key will do lol. i just seem to not be able to fit the notecard defined name into the touch event so it only lets me just test its working additionally also would be great if i could tell the notecard reader and the touch event if no names in the card then allow any one to click. any help on fixing or bug poking this would be great  or some one to show me how to fit it into the touch event properly  . taken me best part of nearly 4 weeks to peice this script together and alot of trial and error but the access list is the last bit before i put it onto sale. and a huge thanks to all forum goers who have lended there time and effort into helping me 
|
|
Very Keynes
LSL is a Virus
Join date: 6 May 2006
Posts: 484
|
09-13-2008 15:21
From: Jodie Suisei ooof i must not be following things properly i just cant get the access list to work with the touch event  What does your access list consist of, keys or names? In the code you post you are converting a key to a name then comparing it to a key. You are then declaring an integer and then searching the list for that unassigned integer. I don't mean to be rude here Jodie, but you keep refusing to post code as it is a product you want to sell, but in all honesty you are not ready to produce commercial content, at least not to the level fo complexity your questions imply you aspire too. How about finding a couple of open source or free ideas, to learn with that we can help and guide you, and then unleash you onto the market with a first rate product when you are ready?
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-13-2008 15:31
From: Very Keynes What does your access list consist of, keys or names? In the code you post you are converting a key to a name then comparing it to a key. You are then declaring an integer and then searching the list for that unassigned integer.
I don't mean to be rude here Jodie, but you keep refusing to post code as it is a product you want to sell, but in all honesty you are not ready to produce commercial content, at least not to the level fo complexity your questions imply you aspire too.
How about finding a couple of open source or free ideas, to learn with that we can help and guide you, and then unleash you onto the market with a first rate product when you are ready? no offence taken at all to what you said there i did post an edit up including what im digging out of my notecard along with along with the dataserver that it is attached to as for freebie open source scripts i already did look for those to base what i was trying to do on i found a few around but totally laid out in a way i couldnt understand so my aim there was to write something from scratch as best i could so i could learn some areas i wanted to try to branch out into for example in this case notecard reading followed by making that read more than one card and pulling data from cards into dialog lists. as for level of complexity i aspire to i just have so many ideas of my own for products and things i have bought in sl the time i have been in either didnt do what i would expect it to or turned out to be free scripts by people resold for the purpose of lining pockets  just thought i may as well try to learn scripting and give my products a new lease of life as personally im sick and tired of selling unscripted stuff all the time it gets old and doesnt really compete with others of the same types around out there. EDIT also i didnt see the point in trying to modify free scripts out there when i learn fastest by learning by doing as for the code i previously posted up i totally messed it up and reverted it back to the way i posted in the edited post a little up before i replied with this post Also why i dont take offence pretty much slapping me across the face for getting things wrong and asking for clarification is a little on the low side why i do take criticism pretty well poking some one for trying to learn as they go and ask the more experienced people for guidance to be poked pretty much in the eye like you did wasnt honestly called for ready for commercial realesing products or not if some one had of poked you like you did me when you was learning and asking for help you would probably feel the same way.
|
|
Pale Spectre
Registered User
Join date: 2 Sep 2005
Posts: 586
|
09-13-2008 15:51
I don't understand this: Access = llParseString2List(data, [""], [" "]); I'm assuming you want your access list to end up looking something like this: list Access = ["Pale Spectre", "Jodie Suisei"]; Therefore in the dataserver event handler you simply need: Access += [data]; So: if (llListFindList(Access, [Avatar]) != -1) ...needs to end up like this: if (llListFindList(["Pale Spectre", "Jodie Suisei"], ["Jodie Suisei"]) != -1) which would return 1 and therefore not be -1. One thing that is always useful is some good debug lines. llOwnerSay(llList2CSV(Access)); will reveal exactly what you have in your list. key Avatar = llDetectedKey(0); will return a key and not a name (e.g. "98ed8ca9-a6e7-4af7-94b0-9d3e2743893b"  . Whereas: string Avatar = llKey2Name(llDetectedKey(0)); will return a name (e.g. "Jodie Suisei"  I'm guessing from your Notecard that you want "Jodie Suisei", and not "98ed8ca9-a6e7-4af7-94b0-9d3e2743893b". ...again llOwnerSay can be used to check all of this. 
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-13-2008 16:02
From: Pale Spectre I don't understand this: Access = llParseString2List(data, [""], [" "]);
I'm assuming you want your access list to end up looking something like this:
list Access = ["Pale Spectre", "Jodie Suisei"];
yes this is exactly what i was attempting to achieve but as i said i thought i had booboo'd badly on that one and wanted to make sure it hadnt got the wrong thing in it. From: Pale Spectre So: if (llListFindList(Access, [Avatar]) != -1)
...needs to end up like this: if (llListFindList(["Pale Spectre", "Jodie Suisei"], ["Jodie Suisei"]) != -1) which would return 1 and therefore not be -1.
One thing that is always useful is some good debug lines. llOwnerSay(llList2CSV(Access)); will reveal exactly what you have in your list. aha thank you for the information on that part also for clarification as you got me a litle boggled is if (llListFindList(Access, [Avatar]) 1= -1 is inputted with the changes to the dataserver event handler it would produce the correct output when the touch event is triggered ? sorry for the questions just want to make sure i dont go breaking the script any more lol or would i need to define every avi name under the sun intot he script who may use the thing? edit fixed the quote thing Double edit thank you Pale your tips and advice work nicely now have the access list controller working correctly using Avatar = llDetectedKey(0); , DetectedName = llDetectedName(0); and then cross checked the detected name against the list now provides either denial if you are not on the list or access with your detectedkey if you are 
|
|
Very Keynes
LSL is a Virus
Join date: 6 May 2006
Posts: 484
|
09-13-2008 22:38
Hi Jody, I honestly did not intend a "poke in the eye", and we are all here to help people, especially people like yourself who are willing, and in fact want to learn by doing and improve their skills. My reference to open source or free scripts I obviously did not express too well (it was 2am my time). What I meant was that you come up with an idea for a product, or even just a function, that you would like to release as open source, so that we can help you develop it without you having to reveal your grand plan. And you can then build it up as a series of smaller modules that you can reuse in later projects. Once again, I am sorry if I hurt you, that was far from my intention, and I along with others here respect what you are trying to archive, It just becomes frustrating trying to help without knowing the larger picture.
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-14-2008 01:45
From: Very Keynes Hi Jody, I honestly did not intend a "poke in the eye", and we are all here to help people, especially people like yourself who are willing, and in fact want to learn by doing and improve their skills. My reference to open source or free scripts I obviously did not express too well (it was 2am my time). What I meant was that you come up with an idea for a product, or even just a function, that you would like to release as open source, so that we can help you develop it without you having to reveal your grand plan. And you can then build it up as a series of smaller modules that you can reuse in later projects. Once again, I am sorry if I hurt you, that was far from my intention, and I along with others here respect what you are trying to archive, It just becomes frustrating trying to help without knowing the larger picture. Its no problem very at all i dont hold grudges kind of petty to be honest in a forum i appreciate your patients and every one else's who have helped in my annoying code fragments and not seeying the large picture. The radio im working on i have decided to post pone for a while longer after all has taken 4 weeks to get it this far from a Hello Avatar script  so a week or so more while i try to tweak the dialog menu based on a couple of examples i found on the forum and in world not quite happy with the way the buttons are laid out so will take it apart bit of bit and eventually finish with something that i got in mind after all it was based on the wiki with Next and Prev Buttons and is a little on the untidy side. i will be updating my product updater thread at some point today i have no problem with making that open source so people can learn from it i know i still am and since i just cant find no open source updaters that you can send to customers that will change there scripts over and put contents into there product without having to do more than a click would be a nice learning curve  Edit ooomf spelling 
|
|
Jodie Suisei
Lost In LSL Code
Join date: 6 Oct 2006
Posts: 66
|
09-15-2008 01:06
i have another question if some one is willing to answer it  i have a note card for example here i want to deal with colour vectors white, <1,1,1> black, <0,0,0> yellow, <1,1,0> now i was looking through the wiki so i could get a vast idea on how to deal with various functions and things i reviewed llCSV2List for seperating stuff from a notecard with comma's and finding data within in for example < > as per the wiki says.. From: LSL Wiki Vectors & Rotations Anything between "<" and ">" is considered a single value regardless of the existence of a comma between.
This ensures that vectors and rotations get treated as a single value, with no additional cleanup needed afterward.
Note, though, that for every "<" there needs to be a corresponding ">" or it will consume the rest of the string now what im confused on is how i can then pick out for example the first item pre comma as say for a button and would like to know would using llSubStringIndex work best for telling it to pick data before the comma as the name to be for example put into a dialog list and the data after to be its associated vector? or would using llCSV2List work better and then converting the < > parts of it to llList2Vector? trying to make just a basic colour changing dialog here nothing overly massive lol making use of notecard reading  Edit i dont have any script to post up just yet as im only thinking about how i would dig out the vector info and use the first bit for the button will post up a basic dialog with it in once i have a clearer picture if i need to bug whack  just did a basic test on using substring to deperate the name and the vector and used llList2CSV to check its output seems to be working will looking into coverting the seperated vectors now and will update this specific post with the resuls 
|