Jump to content

Recommended Posts

https://www.php.net/manual/it/function.register-tick-function.php

Specifically

https://www.php.net/manual/it/control-structures.declare.php#control-structures.declare.ticks

Quote

A tick is an event that occurs for every N low-level tickable statements executed by the parser within the declare block. The value for N is specified using ticks=N within the declare block's directive section.

Honestly, it's not very clear.
Can someone explain it better?

Edited by rick645
Link to comment
https://forums.phpfreaks.com/topic/329083-register_tick_function-and-declareticks/
Share on other sites

  • rick645 changed the title to register_tick_function() and declare(ticks=...)

A tick happens every time the engine does something at a fairly granular level. Like executes a statement, but even lower-level than that.

The easiest way to understand it is going to be to play with code: set up a ticket handler every 1/2/3/whatever ticks, have it output something, and then write a bunch of code to execute and see what happens.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.