STAR TREK 2d20
Page 2 of 2 First 12
  1. #11
    Trenloe's Avatar
    Join Date
    May 2011
    Location
    Colorado, USA
    Posts
    33,362
    Quote Originally Posted by daddyogreman View Post
    Also what does the code for the URL windowclass Look like?
    How is it accessing the value of the string being passed to it if it isn't loading up a db node?
    It's not a windowclass exactly. The base FG application code knows to handle "url" differently - that it won't be a windowclass. All it does is launches the default O/S browser with the value of the second argument (URL string). Then it continues on its merry way, not knowing or caring if the browser opened and displayed the URL.

    So, if you want to try to do something in the browser, you'll need to code something into the resulting resource pointed to by the URL - if it's an HTML page, put some code in to do what it needs to do then close the browser, for example.
    Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!

  2. #12
    So what approach would be suggested here? If the url windowclass isn't necessarily a windowclass, would I have to create a db node to put the url into, create a new windowclass that loads up said db node so it can get at the url string? Looking at the docs for a windowinstance I'm not seeing anything that can actually interact with the OS. Looking at the docs for LUA itself, I do see there's obviously some calls to execute bash commands and the like (os.execute, for instance). I get the need for limiting direct access to the OS, but as stated earlier, obviously there's at least few things that can be done - the url "windowclass" being a good example where it just passes off the call to the OS to open the URL as the OS sees fit.

  3. #13
    Trenloe's Avatar
    Join Date
    May 2011
    Location
    Colorado, USA
    Posts
    33,362
    For security reasons you can't execute operating system commands directly from LUA within FG - they are specifically blocked.

    A FG windowclass is only used for displaying a window within FG. "url" is the only exception to this.

    Let's take a step back. Please give details of what you're trying to do.
    Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!

  4. #14
    I just want a way to, instead of pass the URL off to the OS to handle as it chooses, specify that it should open the URL in a specific way - as in a command line call to a headless browser such as google-chrome --headless <URL> in bash on linux.
    Or any other way to accomplish this. I have no control over the content of the web page being opened, so I can't modify things on that end.
    On a side note, Trenloe you're awesome. Thanks so much for the help.

  5. #15
    Trenloe's Avatar
    Join Date
    May 2011
    Location
    Colorado, USA
    Posts
    33,362
    Quote Originally Posted by daddyogreman View Post
    I just want a way to, instead of pass the URL off to the OS to handle as it chooses, specify that it should open the URL in a specific way - as in a command line call to a headless browser such as google-chrome --headless <URL> in bash on linux.
    Or any other way to accomplish this. I have no control over the content of the web page being opened, so I can't modify things on that end.
    All you can do is open a browser with a URL. That can be a web resource, local file or an application linked to a specifically registered URL class (depending on the operating system you're using).

    If you want to do something more than just open a web page, the URL you use will need to open a specific application, or have some code embedded to do something more - like a local HTML file with code in the HTML, or something similar.
    Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!

  6. #16
    Trenloe's Avatar
    Join Date
    May 2011
    Location
    Colorado, USA
    Posts
    33,362
    Note that your browser can more than likely process URIs rather than just HTTP based URLs. Some info on the difference here: https://www.guru99.com/url-vs-uri-difference.html
    Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!

  7. #17
    I may be able to clarify what daddyogremann wants to do: Seemingly on Linux an url call also shifts the focus to whatever gets opened, unlikely to Windows seemingly (they were testing Celestian's sound extension and sound calls were seemingly resulting into that Syrinscape suddenly had focus and they needed to bring the focus back to FG).

    I am not really an expert for those things, but I still believe that such a possible difference of Linux and Windows may only be changed by SmiteWorks themselves Which is why I suggested Daddyogreman to post here to see what the devs might say about that possible difference

  8. #18
    The interaction with any OS related tasks is done within the engine of the program and not available with ruleset code. So in the case of url, it pipes into the ruleset to allow adding the string for the url, but the processing is done in the engine. The reasoning is for security and if you feel this is a problem with the Linux client, then I would recommend making a post within the Linux Unity thread in the support area of the forums. The dev responsible for that client to investigate.
    Dominic Morta
    Ruleset Developer
    Smiteworks

    How to zip up your campaign if the Developers ask for it-How to zip up your campaign if the Developers ask for it

    How to provide an Unity Connection issue?-Connection Issues and What to Provide

    Unity Updater issue?-Updater Issues

    Classic and Unity Port Forwarding?-Fantasy Grounds Connections Explained

    Comcast or Cox ISP User?-Comcast XFinity and Cox Users

    Have a suggestion?-Feature Request

  9. #19
    Trenloe's Avatar
    Join Date
    May 2011
    Location
    Colorado, USA
    Posts
    33,362
    Quote Originally Posted by Kelrugem View Post
    I may be able to clarify what daddyogremann wants to do: Seemingly on Linux an url call also shifts the focus to whatever gets opened, unlikely to Windows seemingly (they were testing Celestian's sound extension and sound calls were seemingly resulting into that Syrinscape suddenly had focus and they needed to bring the focus back to FG).
    Thanks for the background info. Context is always good when having detailed discussions such as these. I think we're gone beyond just this though...
    Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!

Thread Information

Users Browsing this Thread

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

Bookmarks

Posting Permissions

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

Log in

Log in