ome6a1717's Recent Forum Activity

  • I'm just curious, I'm using the following formula to play SFX and music in my game:

    20 * log10(SoundVolume * 10 / 100)

    SoundVolume is a global variable that the player can set from 0 (mute) to 10 (full volume).

    I have tons of sfx in my game, and every once in a while I decide one might be too soft or too loud. Without having to adjust that in my other application and re-export, is there a quick fix that I can add to the formula that can say "make this sfx 20% louder, but still stay within the confines of the formula"?

  • Actually I've noticed in a past project where I had sine on hundreds of objects; if I set them all to inactive, it didn't really give better performance. However, if I deleted the behavior, it made it much faster.

    Something to consider...

  • UPDATE- as per usual I was being stupid and didn't clear anything on new game...only load game Ignore this

  • I'm nearly finished with my game, and I've finally realized I've made a mistake in the way I'm using dictionaries.

    Long story short, on the start of my game, I'm setting hundreds of values for weapon damage, fire rate, etc. etc. Then as you unlock them in game, I'm adding keys like "weaponUNLOCKED", and checking if it exists for certain UI checks. This works great....until I start a new game after previously playing from a loaded game. I clear the dictionary and reset everything to its default value, however the keys I've added now exist, and are set to 0.

    Any idea on how to fix something like this?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • rexrainbow - is there a way to fade out music if the timescale is 0? I'm trying to fade it out from a pause menu, and it doesn't start the fade until the next layout starts (due to the timescale being reset to 1).

  • nemo - I'll give it a shot, thank you!

  • Desperate bump - I already paid for art with spriter in mind, so if I can't figure this out I'm in trouble

  • Has anyone else had problems using spriter with nwjs? It works great in preview, but when I export it, the sprites are invisible. If I restart the layout, I can usually get the sprites to appear on the 3rd or 4th time I restart (and then it seemingly works from that point forward)

    - Hey Mike, any idea on this? I've saved both scon and scml files (only imported scml). I'm using r244 with the most recent version of nwjs (july 29 2017). I have the initialize event in an inactive group that is initialized on the specific layout/mission start (not sure if that would be a problem).

    Any insight would be very helpful.

  • 99Instances2Go - Thank you. You were right; it's because im not confident it. I really just hate the idea that I can't use saving in a function, and instead have to call triggers. However, I've figured out my problem (and it's pretty much what you said). I just needed to save the data in an array for the save slots and then save everything else to a dictionary. The only thing I needed to do was create a splashscreen that loads everything away from any #includes (so if I call a "local storage item get" somewhere else, I can add specific save and load functions that wouldn't pertain to the first time).

    - This looks great! I'm definitely going to consider this, as well. However, it looks like you still have to check if it's loaded or missing in this, too. Really what I want is to be able to save and load a game in a function without checks, whatsoever (that includes CHANGING said local storage and calling it from a function, expression, etc.)

  • I've looked a bit more into this issue - localstorage just isn't the right tool for multiple saves like I'm trying to do. I'm wondering if anyone has had success in using javascript in creating their own save function plugin?

  • I haven't really played around with LocalStorage much, but all I can tell is it's completely inferior to the older webstorage plugin.

    I'm trying to do the following and having a heck of a time figuring out the best way to do it.

    I have multiple dictionaries, arrays, and global variables that I need saved. In the game, you can have multiple saves to a saveslot, similar to the "save" under the system actions. I then need to be able to get access to the name of all the games (as well as a couple other stats) that exist to put the data into a list that you can select from.

    My original idea was to save everything to a single dictionary, save it to the local storage using AsJson, and then also save a separate local storage called "gameName" (the value of this would be "gamename1;game1time;%completion-gamename2;game1time;%completion-gamename3 " etc. etc. Then, in order to create the list to select from I would do

    repeat(tokencount(LocalStorage.ItemValue, "-")[/code:w2yccgcl] times, and set everything according to 
    
    [code:w2yccgcl]tokenat(tokenat(LocalStorage.itemvalue, loopindex, ";"), <textinstance>, "-")[/code:w2yccgcl]
    
    I assume you're lost by now - me too.  Can anyone else think of a better way to do this?  I don't want to use the built in save and load function because I need more control over it.  The constant "check if item exists, check if item has been gotten after it exists" is super clunky and confusing.  It's making it very difficult to organize this in the way I have my event sheets, functions, and variables.
    
    I'd love to not have to resort to saving to a txt file, but will if I have to.
  • You can't do it with layers, but you can set the button invisible. Al HTML objects will always appear on the top no matter what.

ome6a1717's avatar

ome6a1717

Member since 12 Feb, 2013

Twitter
ome6a1717 has 3 followers

Trophy Case

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

Progress

13/44
How to earn trophies