Jump to content

Gregory McLeod

Resident
  • Posts

    140
  • Joined

  • Last visited

Everything posted by Gregory McLeod

  1. Please ignore this question I have found the answer. memo to self read the WHOLE decription before asking stupid questions. It is assigned starting at 1 so never negative.
  2. Is there any circumstance when the integer returned from a llListen(channel,"",NULL_KEY,"") is negative? If so when and why?
  3. Thank you all for your input. I know know where to look for the solution to my problem,
  4. I am talking about requesting and granting of permissions. Is using the llRequestPermissions(llGetOwner(),PERMISSION_TRIGGER_ANIMATION); always necessary when a script is started. The situation I am having trouble with is creating a HUD. I have everything working but always get failure to get permission to start or stop an animation. If the HUD is attached to the avatar at the bottom right then the HUD is detached it does not seem to get the permission when it is next attached or worn. I thought when an object is attached it automatically gets the permission to trigger animations. Is there something I am missing here?
  5. Thanks, That is what I expected. To do otherwise might lead to spamming attacks of "I am going to get you to load this URL" type!.
  6. Does anyone knnow what happens when a llLoadURL is executed and the Cancel button is clicked? Is there any response given to the script which can be used to determine another action to be taken or does the Cancel not get notified to the script issuing it?
  7. Indeed but what I am looking for is a statement or reference to what other things might or might not be saved along with the HUD. I admit that I have not outlined the whole problem but I am under a non-disclosure agreement.
  8. Thank you that is one more thing that causes problems. Not for me since the HUD I am using has only the one face (face 4) all the others are totally transparent and if the HUD became rotated would apparently disappear. I am still looking for more unexpected things.
  9. At some point in the process of creating a HUD you have to save it to your inventory. I have found that after compiling any scripts their status is preserved when the HUD is taken into inventory. This includes the 'state' that has been reached in the script. For example if after starting default state has caused a change to another state say 'Runtime' while the Runtime state is waiting for an event to commence whatever the HUD is for it will be in stats 'Runtim' when next worn. What else is preserved? I know that a change to the HUD Description is not preserved. I am a little puzzled as I cannot find any references to this. I have chosen to create this new message in the Building and Texturing forum if anyone feels that I should ask again in the LSL Scripting form I will gladly do so.
  10. I have an object that contains a script which I want to give to another avatar but I don't want them to able to modify it or copy it or transfer it. I can set the permissions for Modify and Copy OK but cannot change the Transfer permission. I can change the Transfer checkbox only if the Copy box is checked. But if I then uncheck the Copy box the Transfer permission is reset to checked. How is it done?
  11. I thought you might like to know I have solved the problem I was having. I have constructed the HUD as above but after building it and embedding the script and setting the Object Description to the value required I attached the HUD where I wanted it. The attach in the default state updates the key and nonce from the description and then blanks the Object Description. I then drop the HUD. This allows me to take it back into memeory with the blanked description as required. It is of course now saved in the Initiaize state so that attaching or wearing does not do the initial setup again as the test for the gbReset value causes it to immedaitely go to the Initilize state.
  12. In the design I have created the HUD consists of a single prim, there are no child prims but your suggestion could be useful. I will investigate. Thank you.
  13. I did not make it clear that the value in the Object description will be saved in variables when the object is attached. What I need to do is delete the entry in the description. The value could be permanently stored in the object but if the object is copied by a method I know the key and nonce would become visible. I do not believe I can rely on the permissions of the object to prevent that happening. The object and the scripts are no-copy no-modify but that doesn't stop the copying I know of being done.
  14. I am designing a HUD in which there has to be a key and a nonce to protect the HUD's access to a website. If I create a simple HUD which the default state has an action which stores the parts (key and noce) which are initially stored in the object description, parsed by the script and stored in variables I have found that when the HUD is detached the function llSetObjectDesc("") has had no effect. Reading the LSL portal page for llSetObjectDesc gives the message that any changes are not reflected in the inventory object and I think this is why my setting is getting lost. How do I change the description to "" and have it preserved when the HUD is detached? OR Am I going about it the wrong way? EXAMPLE key gkNullKey = NULL_KEY; string gsGameKey = ""; list gaEmpty = []; integer giGameNonce = 0; integer gbReset = TRUE; //=============================================================================== // State default // This state loads creator setup info //=============================================================================== default { //--------------------------------------------------------------------------- // state_entry event //--------------------------------------------------------------------------- state_entry() { llOwnerSay((string)llGetFreeMemory()); llSetTimerEvent(0.0); if (gbReset) { gbReset = FALSE; } else state Initialize; } //--------------------------------------------------------------------------- // attach event //--------------------------------------------------------------------------- attach(key pkOwner) { list laData; if (pkOwner != gkNullKey) { laData = llParseStringKeepNulls(llGetObjectDesc(),["~"],gaEmpty); llSetObjectDesc(""); gsGameKey = llList2String(laData,0); giGameNonce = (integer)llList2String(laData,1); if ((gsGameKey != "") && (gsGameKey != "(No Description)") && (giGameNonce != 0)) { llOwnerSay("Game data set up!"); llOwnerSay("gsGameKey: " + (string)gsGameKey); llOwnerSay("giGameNonce: " + (string)giGameNonce); state Initialize; } else llOwnerSay("Invalid game data!"); llOwnerSay("gsGameKey: " + (string)gsGameKey); llOwnerSay("giGameNonce: " + (string)giGameNonce); } } } //=============================================================================== // State Initialize // This state checks for updates, tampering, and gets play state from game. //=============================================================================== state Initialize { state_entry() { llOwnerSay("Initialize_state_entry"); } attach(key pkOwner) { if (pkOwner != gkNullKey) { state default; } } touch_start(integer total_number) { llOwnerSay("Initialize_touch_start"); llOwnerSay("gsGameKey: " + (string)gsGameKey); llOwnerSay("giGameNonce: " + (string)giGameNonce); state default; } state_exit() { llOwnerSay("Initialize_state_exit"); } }
  15. Thanks to both of you. I should have looked a little harder for the answer.
  16. How do I show the viewer version number that I am using?
  17. I have finally got down to the bottom of the new terms of service and there is a link to the archive of previous terms.
  18. Where can I get a copy of the Second Life Terms of Service prior to the one that came into effect yesterdya May 7th 2013?
  19. #Darkie I am not exactly clear myself how it can be done, but then I would never try to cheat so don't think the way some people do. I just take instructions from the Game owner to implement the scripts. I give you an example:- if I and my Alt were playing a game which relied on passing a ball. I could know which way my alt was going to go and so be able to pass in their direction. ============ #Curious I don't understand your point about being easier to get two avatars in world at the same time I do it frequently. ============ #Miranda I refer you to the example above in answer to one of your points. I understand the need to release the URL when the game is finished. The Games last for many minutes sometimes 2 hours. The scores are captured by another prim near the field, in fact it detects the events that are scored. None of the objects used in the game including the HUD are modifiable, copyiable or transferable by the player, all the scripts are secured and cannot be viewed. =============== Thanks to you all for responding.
  20. Thanks to all who replied. I will be a little more specific:- The script that I am working on is part of a multi-player game which cannot cross sim boundaries. The problem is that using an alt the original owner and their alt may collude to cheat the system. The HUD MUST be worn to play the game and certain atrtributes must be adhered to or the HUD will detach itself. The players must preregister with the website to be eligible to play the game wherever it is being played.. The game proper (not practice) requires the player to join a team Red or Blue. Currently the joining is done through a prim just outside the field of play and it communicates with the website. This however causes a bottleneck in that all the players trying to use the Team joining script overloads the website and delays the starting of the game. I want to provide a means whereby the action of wearing the HUD will cause a registration event at the website and for the duration of the game will check the player's compliance by using somethiing that is unique to that player (a token perhaps). It could go somethng like Avatar wears HUD HUD goes to website and checks the registration status If registered it displays an offer to view a webpage. The avatar accepts the offer and has a key value displayed which must be entered into the HUD prompting for it. Each different avatar gets a different key value and failure to enter it causes the HUD to detach. Can anyone see any problems with that?
  21. Thanks again for the reply. The problem is caused by some avatars using alts! If an avatar has an alternative user name they will also have an alternative OwnerKey. So we cannot distinguish between two avatars both being driven by one person. The object of my trying to understand the HTTP process (apart from learning about it) is to verify whether the suggested use of IP address would enable two avatars to be distinguished. Now two avatars (one an alt) would not be distinguishable from one another using IP addresses as discussed above, but an interaction with a website should be able to do it. I am getting a little of topic here but the problem is trying to be completely sure that if the IP method does not do it, the method I propose is competely secure.
  22. Thanks for your reply. I probably, through ignorance, phrased the question badly, sorry. What I meant was if it was required to distinguish between multiple avatars all wearing a HUD it has been suggested that knowing their IP address would work. I need to understand the mechanism of the use of IP address within SL. For example if an avatar interacts with the HUD to "activate" it, the HUD script could request a URL as if it were going to be able to respond to an http_request. An outgoing message would give the requested URL. If the HUD only releases the URL when it is detached (thus releasing the URL) the avatar can be uniquely addressed by the given URL. Or have I misunderstood the whole thing?
  23. I have a script which currently communicates with an external website. Each time an avatar interacts with the prim containing the script a message is sent via llHTTPRequest using the POST method and then waits for the response with the http_response event. My understanding of this is that the sim generates the communications with the external website using an IP address that it has and this will be contained in the message header which allows the website to generate a response to that IP address. My question/s 1. Will the IP address be the same for all communications from the prim (unless region restarted)? 2. If an avatar is wearing a HUD (essentially an attached prim) and that prim sends a similar message to the website will the IP address used be the same for all avatars in the sim or region? 3. If the answer to the last is yes do I need to make a request for a URL (llRequestURL) and will the same sort of POST message use the URL?
  24. Rollig, It was not your reply I was referring to as "not helpful". I apologise if I gave that impression as I know you of old and respect your contributions highly. It appears that my clicking the reply button under the input from leprekhaun did not attach my reply to his input but at the end. My sincere apologies for my bad. Your latest very helpful input has given me the key to a problem I was having trying to decipher some code (not mine) and for the life of me I could not find where the ball got itself attached to the avatar. I can see it now it is all to do with a HUD which is attached to the avatar and from that it would be able to set the llMoveToTarget after rezzing the ball. Thanks again.
×
×
  • Create New...