hmott's Recent Forum Activity

  • jan2000

    I probably wont get it yet. But if I do, I'll let you know.

  • I came across a new board that includes windows 10 and arduino at lattepanda.com

    If I wanted to build a arduino robot/car, could this board just be plugged into it? How would it work and what other peripherals might it need?

    Thanks for making this plugin btw.

    Henry

  • [quote:4ali2fru] I've added the word "start" in front of the folder I want to open

    or you can just replace word "start" with "explorer "

    "explorer ""C:\Program Files"""[/code:4ali2fru]
    [code:4ali2fru]"explorer ""C:\Program Files\Microsoft SQL Server"""[/code:4ali2fru]
    
    [img="http://lookpic.com/O/i2/1048/ZbF6FsFl.png"]
    
    
    In the desktop program I've created, I put in a "paste" button that copies the clipboard content and sends it to a text object for the user to see.  It then also checks if the folder exists, and if it does, it displays a list of its subfolders.
    
    I've run into the problem of special characters in the file path.  When there are periods in the filepath, checking for the existence of the filepath causes an error.  When there is an ampersands (&) in the filepath, checking for the folder works, but using the "open folder" command opens an explorer window, but not the filepath obtained from the clipboard.
    
    Pasting the file path directly into an explorer window always seems to work if the folder exists.  Any ideas on how to handle special characters in the filepath in the nwjs plugin to prevent errors?
  • [quote:2ulody99] I've added the word "start" in front of the folder I want to open

    or you can just replace word "start" with "explorer "

    "explorer ""C:\Program Files"""[/code:2ulody99]
    [code:2ulody99]"explorer ""C:\Program Files\Microsoft SQL Server"""[/code:2ulody99]
    
    [img="http://lookpic.com/O/i2/1048/ZbF6FsFl.png"]
    
    
    Yes, or that.
  • I've found something from this link

    http://stackoverflow.com/questions/1880 ... in-windows

    [quote:1pdydrxm]A workaround I use is to use the "short names" for the directories in the path, instead of their standard, human-readable versions. So e.g. for C:\Program Files\ I would use C:\PROGRA~1\ You can find the short name equivalents using dir /x.

    The basics is the first six characters in uppercase, followed by a tilde, then a number to differentiate multiple folders with the same first six characters.

    "C:\PROGRA" + "~" + "1"

    This numeric approach will eventually break if you have multiple folders with the same first six characters. But windows uses this short-form convention on all folders and starts getting creative with it. You'll have to find exactly which short form windows has assigned the folder you want. To find it, press and hold the windows key, then press "R", which will bring up the "Run" window. Type "cmd" to bring up a dos command window from the 1890's (or 80's?).

    Navigate to the folder that has within it the folders you want to see the short forms for. Then type "dir /x". A table of the folders in the current directory will appear along with their short forms.

    Then replace the folder path component with spaces in it with this short form.

    Then you can set a variable in c2 to "start c:\PROGRA~1\SUBFOL~1\..." without any quotes. Once this runs, windows will then recognize the short forms and open you folder.

    Easy, right? <img src="{SMILIES_PATH}/icon_e_biggrin.gif" alt=":D" title="Very Happy">

  • Thanks korbaach,

    I forgot to mention that I'm looking to apply this method to open a folder, not run an executable.

    Using the variable method and a text box in the app as the input, I can run an executable with quotes:

    "c:\Program Files\program.exe"

    Using the same input box, I've added the word "start" in front of the folder I want to open. But this only works with folder paths without spaces, like "c:\". Once I add spaces, I haven't yet found a way to make it work.

  • In the NWjs plugin, the action "File System > Run file" says:

    [quote:30m53pe5]To execute a path with spaces in it, wrap in double-quotes (e.g. """C:\Program Files\file.exe""").

    How can this be done?

    I've tried using many combinations of quote marks, as variables or directly using (&" ' ' ' ' ") in multiple combinations.

    Any concrete examples?

    Thx

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Try:

    NWjs | Run "start" for a CMD and

    NWjs | Run "start pathToBatFile" for a batch-file

    for example:

    NWjs | Run "start c:\mybat\batch.bat"

    This worked for me too, except when there are spaces in the file path, "c:\first folder\second folder\...". Somewhere I read that we should use double quotes (run | "start" """c:\first folder\..."""), but I haven't been able to make it work.

    Any ideas?

  • Awesome plugins! Thanks Rex.

    The marker plugin has a "draggable" function which crashes on startup...

  • Impressive plugin! Intuitive and even displays in a user-friendly way during debug. Can't wait to use it.

  • Not a bad little game although I do find it annoying that the missiles just fly straight through the asteroids, would be better if you could lose them by them smashing into the asteroids

    Also the upgrade prices are a little steep

    That was the intent in the beginning, but it became a more complicated problem to implement. There were so few missiles reaching the player that they could have almost been ignored. Then implementing "smart" missiles had its own problems with too many "if-then" patches that still didn't work as expected. I may tackle that problem again in the future now that I've had some time away from it.

  • The game is good but will feel a little grindy with the prices of of upgrades compared to how. The difficulty is a little tough when you start those missiles give a good chase but the player will get the hang of it after 3-5 tries. The game is solid but in the future when making a similar game just adjust prices of items.

    Thanks for the feedback! It's tricky finding that sweet spot between the game's challenges and rewards.

hmott's avatar

hmott

Member since 13 Nov, 2012

None one is following hmott yet!

Trophy Case

  • 12-Year Club

Progress

12/44
How to earn trophies