Results 1 to 4 of 4

Thread: Sharing information among simbas

  1. #1
    Join Date
    Jan 2011
    Posts
    121
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Sharing information among simbas

    Hey guys. So for my next scripting project (hopefully one that will get me membership ) I need to share information (variables, basically integers and strings) between two or more instances of Simba.

    I'm just starting with two instances. One is a master, one is a slave. The master creates an INI and then both read it in loops to monitor it and write back to it when necessary. The only problem is when one is writing and the other tries to read (I think) I get a permissions exception.

    Any suggestions? Idk if anyone has tried this before or posted about it if they have.

  2. #2
    Join Date
    Jan 2008
    Location
    Ontario, Canada
    Posts
    7,805
    Mentioned
    5 Post(s)
    Quoted
    3 Post(s)

    Default

    Perhaps just encase the read in a try..except construct, then loop until you can read it. Just waiting a certain time before trying again. Eventually, the read write will be allowed.

    There is also a "shared" property with read/writing of files. Not sure if Simba implements it natively, though.
    Writing an SRL Member Application | [Updated] Pascal Scripting Statements
    My GitHub

    Progress Report:
    13:46 <@BenLand100> <SourceCode> @BenLand100: what you have just said shows you 
                        have serious physchological problems
    13:46 <@BenLand100> HE GETS IT!
    13:46 <@BenLand100> HE FINALLY GETS IT!!!!1

  3. #3
    Join Date
    Jan 2008
    Location
    10° north of Hell
    Posts
    2,035
    Mentioned
    65 Post(s)
    Quoted
    164 Post(s)

    Default

    Could use sockets? Tho the server side would be blocked tho you could make a server script and the clients can communicate thru the server.

    Dg's Small Procedures | IRC Quotes
    Thank Wishlah for my nice new avatar!
    Quote Originally Posted by IRC
    [22:12:05] <Dgby714> Im agnostic
    [22:12:36] <Blumblebee> :O ...you can read minds

  4. #4
    Join Date
    Jan 2011
    Posts
    121
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Wow... I never knew there was a try-except structure in pascal. Learn something new everyday.

    Sockets would probably work but are slightly over my head haha! Thanks for the help guys.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •