1. #1

    Counters don't display decimals?!

    Im surprised I haven't come across this before, but its annoying. All I wanted to do was make a counter for the players age, the year represented by the whole number, and the month represented by the decimal. Now if I want the player to see these two bits of info I need to use 2 counters, or create my own using editor pieces and tons of logic, such a pain. Then to make matters worse one of the filters doesn't send impulses the way it should, despite the logic making sense. Im not even looking for help, or considering a workaround. I figure it's a bug. I'm so irritated with this game.
    Share this post

  2. #2
    mutetus's Avatar Trials Developer
    Join Date
    Dec 2013
    Location
    The land of fin.
    Posts
    859
    Set the counter type to distance.
    Share this post

  3. #3
    Oops... walked right into that one. Though it would still have an extra number on the end, and the "m" which would be confusing. I'll have to explain to the player what it all means. Now if only the counter system I made worked like its supposed too... I'll get a short video up to show what its doing, hopefully someone can show me what stupid thing I did, or confirm that it's a bug.
    Share this post

  4. #4
    Nevermind the video. The numbers are impossible to see from my cell phone.

    I guess I'll try to explain it. I have a filter sending impulses to sate events both on true and on false. It is to do so when the data source it's reading equals .12. For some reason, it only fires off the "true" impulse when it's at .12 ONLY when the data source originally starts anywhere from .9-.12. If its .1-.8 it doesn't fire the impulse on true when the data source reaches the .12. THEN, even if it's in the .9-.12 range and works, the system will reset the data source back to .1, as it should, but when it climbs back to .12, the filter doesn't send the "on true" impulse. It makes no sense.
    Share this post

  5. #5
    mutetus's Avatar Trials Developer
    Join Date
    Dec 2013
    Location
    The land of fin.
    Posts
    859
    You shouldn't use "equals" with decimal numbers. As the values in data sources are floating point numbers there ought to be some round off errors when adding them even though the number seems correct on the icon. When you start from .9 like you said and increase the number by .1 three times, there's a chance it'll still be exactly .12 but if you start adding from .1 the final number might be .119999... which won't match. Unfortunately it's not some flaw in the editor, it's a common thing in programming. You can see what's it all about if you multiply the resulting number by 1,000,000 or something.
    Share this post

  6. #6
    Originally Posted by mutetus Go to original post
    You shouldn't use "equals" with decimal numbers. As the values in data sources are floating point numbers there ought to be some round off errors when adding them even though the number seems correct on the icon. When you start from .9 like you said and increase the number by .1 three times, there's a chance it'll still be exactly .12 but if you start adding from .1 the final number might be .119999... which won't match. Unfortunately it's not some flaw in the editor, it's a common thing in programming. You can see what's it all about if you multiply the resulting number by 1,000,000 or something.
    That's crazy! *mindblown* I had no idea there was a place where math didn't make normal sense....well, thanks for that...I guess I'll have to redo it in a way that the editor can't deceive me.

    Request for future trials- if the game is coming up with remainders somehow, it would be great if numbers didn't get rounded, and it would show a little "r" and the remainder, so there's no funny business.
    Share this post

  7. #7
    Fixed it. Just made the decimal value event into whole numbers, then divided the data source by 100 to get my decimal AFTER it went through the filter process, now it works perfectly! Thanks smart guy.

    And if you could tell the guys in charge to allow counters in generic format to show decimals in a future update, thatd make me super happy
    Share this post

  8. #8
    The calculator on my phone does this
    Share this post