Levyman's Forum Posts

  • Ahh thanks that is working now! but i think i asked the wrong question :( but this works, i probably didn't want JSON because that is easy to edit and for people to cheat their values, how do i export it so it's like unreadable? i mean i see their export text and it's like "hkef3dsA" etc

  • All i get what's in the editbox is just {"c2dictionary":true,"data":{}}

  • Thanks! this looks like what i am looking for but how are you creating player.health? you can't create a variable called player.health or object with that name

  • I have recently uploaded my game to kongregate, but i am having a lot of users have problems with saving/loading issues.

    I have the rex.Json plugin installed and JSONmanager installed but i can't seem to work out how to write my variables to a JSON file which exports so you can copy and paste it and store it in say a text document, then if people lose saves they can just copy and paste their JSON text into the game and i can import it.

    This obviously is quite common in a lot of games and it's more safer than the browser save.

    Any ideas how to do this? thanks

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Yea lol.

    Well i haven't tried using sprite fonts yet :/ i didn't know they had such better performance, so thanks for the tip on that one, i really wished there was an easier solution though, it's been a nightmare 2 days with this thing lol

  • My project is pretty big because i am making a game but hopefully you can see the screenshot, the problem was with adding & "Billion" at the end to them 3 events, it would flicker sometimes on check 2 or check 1 and i just couldn't figure it out.

    Very happy England are through man!

    And i checked your project and removed the space bar but even on 60 frames a second you will see it flickers sometimes, it's something to do with the rounding i think but you can watch it and see it might jump sometimes which would make the word Billion jump and it looks strange.

  • But i have a working solution with your help :) and learning how to separate the variable was key so i really thank you for it

  • I checked that project and they are not in timers, when adding just "0" it seemed fine but when adding "00" or "000" with "Billion" it would always flicker especially on a quick timer or every tick, so in the end i just added a separate text box that will display "Billion" or "Trillion" and so on and i get no flicker, i didn't use the str function though for the last part with "billion" so maybe it might of been the problem.

  • Tried everything and it still flickers a little, it's a pity i can't just stop automatic rounding at all, even when it hits 2 characters and i just put & 0 it still flickers a little, so i just don't understand how to get it to work

  • BillionCheck to int(Variable / 10^9 * 1000) /1000

    Beforedec to tokenat(BillionCheck & "Beforedec . Afterdec",0,".")

    Afterdec to tokenat(BillionCheck & "Beforedec . Afterdec",1,".")

    Checkdec to len(str(Afterdec))

    every tick

    Checkdec = 2

  • BillionCheck to int(Variable / 10^9 * 1000) /1000

    BillionCheck2 to tokenat("Beforedec . Afterdec",1,".")

    On every tick but just returning a Nan value.

    To be honest this just looks wrong as i post it but have no clue how to fix it

  • Thanks! :) this is a bit beyond me and it's only my 2nd week using construct 3, how would you write that?

    i current have every tick to check for Variable => 10^9 < 10^12 then i will go to => 10^12 < 10^15 for trillions etc

  • So i have the event right to return me the value of billions with 3 decimal places but i am using this event on a fast timer and anytime it goes to a 0 it will round up to shorter decimal places, example being 123.130 becomes 123.13, I want to always keep 3 decimal places, looked on a lot of posts but can't seem to find the right answer, please help been stuck on this for a day now :(

    Set Text:round(Variable / 10^9 * 1000) / 1000