Jump to content

Wymoree

Resident
  • Posts

    3
  • Joined

  • Last visited

Reputation

0 Neutral

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Okay. So stepping back from the StaNav HUD project madness. I am pivotting over to the bus announcement script that I had started a while couple weeks ago. This is meant to be a prim worn by an avatar that will provide ADA and other service related announcements. I am trying to make it easier for users to quickly reconfigure their announcement when swapping to a new route. It's features include/should include. Posting messages at certain times (Need Improvement - I'd rather have it select a random message from a list each run but right each message is based on a certain static time or interval with in a 5 minute window.)Reading Config From Notecard (WIP - Trying to get this working but the rest of the scipt is functionally brokenCurrent Issue: For some reason after introducing the notecard reading functionality it doesn't even signal to the user that it was attached or anything is loaded. I can't even start the timer using the "/9 enableann" trigger. The only i/o I get from it is when the config notecard doesn't exist. Here is the script: integer count; integer ON; key gSetupQueryId; integer gSetupNotecardLine; string gSetupNotecardName = "Config"; //define config variables here string ServiceRoute; string ServiceNumer; string DriverID; readSettingsNotecard() { gSetupNotecardLine = 0; gSetupQueryId = llGetNotecardLine(gSetupNotecardName,gSetupNotecardLine); } default { attach(key id) { if (id) // is a valid key and not NULL_KEY { llOwnerSay("ARTA Bus Announcements v. 0.1 Loaded! Use \"/9 enableann\" to enable the messages."); } else { llOwnerSay("ARTA Bus Announcements v. 0.1 Unloaded! Have a great day!"); } } state_entry() { // Check the notecard exists, and has been saved if (llGetInventoryKey(gSetupNotecardName) == NULL_KEY) { llOwnerSay( "Notecard '" + gSetupNotecardName + "' missing or unwritten"); return; } // listen on channel nine (9) for any chat spoken by the object owner. llListen(9,"",llGetOwner(),""); readSettingsNotecard(); } listen(integer channel, string name, key id, string message) { if (llToLower(message) == "enableann") { llOwnerSay("ADA announcements successfully Reset. Use \"/9 enableann\". to renable announcements."); llSetTimerEvent(0.0); } if (llToLower(message) == "enableann") { llOwnerSay("ARTA Bus Announcements successfully enabled. Use \"/6 disableann\". to disable announcements."); llSetTimerEvent(1.0* (ON = !ON)); //Turns timer ON and OFF } } dataserver(key queryId, string data) { if(queryId == gSetupQueryId) { if(data != EOF) { list tmp = llParseString2List(data, ["="], []); string setting = llList2String(tmp,0); if (setting == "ServiceRoute") { ServiceRoute=llList2String(tmp,1); } //add more if statements here, for each config variable //you can also do stuff like variable=val1,val2,val3, simply //do llCSV2List(llList2String(tmp,1)); gSetupQueryId = llGetNotecardLine(gSetupNotecardName,++gSetupNotecardLine); } else { state running; } } } changed(integer change) { if (change&CHANGED_INVENTORY) llResetScript(); } timer() { ++count; if(count%30 == 0) { llSay(0,"Route 57 service to "+ServiceRoute); } if(count == 60) { //Say this message at the one (1) minute mark llSay(0,"Please make priority seating available to passengers with disabiltites and seniors."); } if(count == 120) { //Say this message at the two (2) minute llSay(0,"Driven by operator 15484"); } if(count == 240) { //Say this message at the four (4) minute mark llSay(0, "Please be curterous. Riders and strollers must share space aboard the bus."); } if(count == 300) { //Reset script time and restart messages from first message llGetAndResetTime(); llSetTimerEvent(1.0* (ON = !ON)); //Turns timer ON and OFF llOwnerSay("Meeasge Timer Reset."); } } } state running { changed(integer change) { if (change&CHANGED_INVENTORY) llResetScript(); } }Any ideas? Thnak you in advance for any help rendered.
  2. I forgot to mention that I am relativly new to LSL scripting. I have managed to write a script that whille loop through messages on a set timer. I am flying blind here so I aplogize for my ineptitude. So the bottom layer would be the map. Layers in between would be the differnt routes (??) [ideally these should be filterable so the drivers can focus on their assigned route] The top layer would be the yellow dot marking the driver's current position (??)
  3. I am the Directory of Transportation for the Town of Avon. I am trying to make a HUD for my drivers so they can see where they are and their route. How do I make a map HUD that traces out the route. I can find plenty of scripts to achieve the first part but can't seem to figure out the second part. Thank you in advance for any help.
×
×
  • Create New...