neuroxik's Recent Forum Activity

  • We are using NWjs.UserFolder & "Documents" in our game, but there is a bug where the app loses permission after an update:

    https://www.construct.net/en/forum/construct-3/general-discussion-7/steam-game-macos-folder-179106

    Hm, good to know, thanks

  • Thanks a lot for taking the time to reply :)

  • Hey everyone,

    I have a save game set up which uses this path on PC:

    NWjs.UserFolder & "\Documents"

    I cannot test on Mac OSX because I don't own one and know no one who does in my surroundings, so my questions are:

    1. Does the "NWjs.UserFolder" point to a valid user's path on Mac?

    2. Does the trailing "\Documents" exist on Mac?

    Thanks for any replies :)

    Tagged:

  • I want to bypass using localStorage mainly because I don't want 2 copies of save games (and the game totals ~700 MB), using NWJS (exporting as such), and only saving game values as json in the UserProfile directory. Everything seems neat and dandy so far (although I'm not done) but I can't find (I've read the manual) a way to tell if something went from. On CONDITIONS, such as "NWJS -> Path NWjs.UserFolder & SaveGame_SubDir exists", I *can* put an "Else" so at least I know, alright, that directory doesn't exist.

    But, when it comes to Actions, such as NWJS -> Write File -> "Write 'something' to file NWjs.UserFolder & SaveGame_File", there are none of the following, or at least that I can find: either an Else (which I can understand) or "if write to file fails", or "has write file finished?" (so that I can stop displaying a "Saving" text and/or icon)

    Is there a workaround to know if something fails? I don't need a baked response, even links to other resources might help :)

  • Well you would just need one event for this, when you overlap a sign i.e. player is overlapping sign, you set the text to sign.variable where the variable is the text to be displayed.

    Yah, for that scenario that would work (just tested it). Don't know why I wouldn't get my variable in my case, maybe because I had more than one instance variable? I don't know, will have to test that later. Thanks

  • [..] the question is why would you want that?

    The reason is I want text to popup in a 9-patch when you overlap certain objects like Signs, Doors, and maybe some other players. While all this is working quite fine, it becomes hard to maintain when you have 200+ events just for checking which sign type you're currently overlapping (I'm putting "door" and "other player" in the same category as "sign" just for the sake of the example) and then which particular sign. Ie.: Is it the 1st sign where you tell a hint, or the 50th in Level 30 where you're telling the player he needs object X to be able to perform a certain task.

    I know this is very doable in a more procedural fashion, listing

    if signID = 1, do this if signID = 2, do that [so on]

    AND have sub-checks checking if it's a door (using different design for the 9-patch), a sign or whatever. So having ONE function (which I did) handle all of that, and handling which is which all without a thousand if/elseif's seemed a more elegant solution (coming from a programmer's background like myself).

    Good news though is I fell upon "pick by evaluate" which then allows me to make direct reference to that object's instance variable value (which solves my problem for getting an object's instance var), and I put those 3 objects in the same family. I don't understand why "pick by evaluate", which to me seemed to be a trigger that will allow sub-events (those nested under) if their value is not 0, allows to then make direct reference to that (in this case) instance variable current value, but hey, I won't complain, it's solving 99% of my problem!

    If you overlap sprite3 it becomes the picked object so technically you could pull the instance variables from it with events and set text to those values.

    How would you go about that? The only thing I came across (still new to Construct) "pickedCount".

  • Hey everyone,

    I have two things I want to acheive in order to make my code more modular when shooting some things through functions. If you know any one of these 2 following questions, I'll hugely appreciate (or point me in a direction). If you can answer both, even better :) Otherwise, any input is appreciated!

    1 - Getting the current object's name

    =====================================

    Say I'm overlapping an object called sign, can I get the name of that object (example "Sprite3") as in the pseudo-code below? :

    (forgive my code below, I don't have the preview or edit option with my limited privileges as new member)

    if { (isOverlappingObject == 'Sprite3') { setTxt("This object's name is: " & currentObjectName); } }

    2 - Getting the current object's instance var(s)

    =====================================

    This one is less important because I can always otherwise do if/elseif's to judge an object's instance variables, but as in my 1st question, when overlapping an object, is it possible to get a list of its instance variables?

  • You simply need to create/spawn particles object when you want to trigger it.

    Thanks! Yeah, I'd found it since, I would've happily deleted this post but it was awaiting moderation. I don't know the minimum post count before they're posted immediately. Anyhow, thanks!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hey everyone,

    I can't seem to find an option / way to trigger a particles effect on demand. Am I looking for this in vain or is there a way? Thanks :)

  • > "Run layout" option does exactly what it says - it runs the current layout only. Therefore the loader layout is not shown.

    Hm, I see. Yah, I was doing Run Layout. Just tested it with run project and the loader initiates. I understand now it makes sense since someone will play from the intro, where it be Menu or whatever, and then load to Level 4 if that's where his save point is. Thanks!

  • Hey everyone,

    So I've set up my custom loading screen as detailed in Ashley's tutorial, and although it

    1 - works as expected, including my custom progress bar expanding until 100% of the width

    2 - Then set to "go to next layout" (which it does for my Intro), and the file is also the FIRST

    3 - Use Loader Layout -> Yes (in project settings)

    If I click (PC) on Preview from a level, say Level 4, it still uses Scrirra's default loader.

    I deduced it might come from, quoting Ashley's tut: "Loader layouts are only ever shown the very first time the game is being downloaded from the web [..]". So I imported the Browser object / plugin in my project but still can't figure out how to go about it even after trying a couple triggers & actions browser-related. Did anybody achieve this?

  • This is INCREDIBLE!! So many kudos to you for creating this! I was searching & searching for a straightforward approach to arrays rather than the less intuituve x,y,z axis, I come from a php background and you can use strings as indexes & wanted to teach my son the power of arrays but I felt Construct lacked on that. I do admit that 99% of the work Tom & Ashley have done is VERY intuitive, it's permitted my son to have an easier introduction to game engines and for that, it's excellent, but yah, your addon is a godsend! Thanks!

neuroxik's avatar

neuroxik

Member since 7 Nov, 2018

None one is following neuroxik yet!

Trophy Case

  • 5-Year Club
  • RTFM Read the fabulous manual
  • Email Verified

Progress

7/44
How to earn trophies