[Plugin] System date and time

From the Asset Store
Control your space ship in a weird space-time environment and destroy as many enemies as you can!
  • striimix

    You might try expression:Date.Date , since Date.Day is day in a week i.e. 3 is Wednesday.

    Ahh, of course - thanks!

  • Thanks Rex! Very useful! Thanks for the hardwork. Anyway, I wanted to make more use if the time away plugin for example: After the user runs out of ammo, they need to wait for 10 hours to be able to automatically add ammo to the game. Is this possible? I would need your help. Thanks so much!

  • Hey rexrainbow I have a small question about "time away L plugin". Is there a way to remove unused timers from local storage?

    My events are quite simple, they goes like this:

    +Variable = 1

    ++every 1 second -> TimeAwayL: Start timer "xxx"

    +Else

    +Trigger once - > "stop timer" ???

    When Variable is not equal to 1 I don't need timers to save anything anymore, but I can't get rid of them.

    Been trying to use LocalStorage: Remove item "xxx" but it's not working, Everytime I run the project I can see saved timer items and values in the local storage

  • Update

    rex_timeaway , rex_timeawayL plugin: add action: remove timer

    shinkan

    Try this new one.

  • rexrainbow

    Thank you. Works perfectly.

  • Hello rexrainbow ,

    I'm developing a game where It is really important to measure keypress time as accurately as possible. In tests comparing C2's ability to timestamp time correctly (using your plugin), I get a non-constant variation of about 150ms while compared to a psychophysics measurement software that uses the hardware clock (In linux, hwclock). Do you know if it is possible to access this clock as opposed to the system clock like your date plugin does? And if your plugin does not allow it, do you think it is possible to do inside construct 2?

    Best,

    Tiago

  • quendera

    The api of accessing current time comes from browser.

  • Thank you!

    Is there a way I can thank you for all the plugins other then with my eternal appreciation?

    Best,

    Tiago

  • Hey rexrainbow, From where do I download the plugin?

  • Hey rexrainbow, From where do I download the plugin?

    The links are all available in the first post on page 1, which is nearly always the case on forums.

  • Yes, but I can't find the download link on his site...

    The links are all available in the first post on page 1, which is nearly always the case on forums.

  • The download links on your site for this plugin down work, they link to dropbox files that are deleted.

    You can get the plugin from your plugin tool though.

  • is there a way to calculate the number of days between two dates (different months too)

  • Try Construct 3

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

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

    1. Get two timestamp t0, t1.

    2. Get delta time T = ( t1 - t0 ) / 1000 , in seconds

    3. Convert T (seconds) to days or months.

  • rexrainbow - are t0 and t1 in scale of days? How do I tell it with an expression to calculate the day,month and year of t1 and t0?

    This is very confusing, can you post an example?

    Do I convert t0 and t1 to a unix timestamp values, then calculate the difference and convert back to normal timestamp?

    What is the expression to convert back to normal?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)