(Redirected from Incr Counter (block))

The block documented in this article is a hidden block, meaning that while it technically still exists in the latest version of Scratch (3.0), it is not available in the palette.
Increment Counter
increment counter :: control
Category Experimental (in 2.0), Control (in 3.0)
Type Stack
incr counter:: #c3af00
The Incr Counter block's appearance in Scratch 2.0.

The increment counter block is a stack block and a control block. It increments the value of the counter by 1, which can be reported with the counter block and set to 0 with the clear counter block. This block was originally added as an experimental block in Scratch 2.0 under the name "incr counter", and like all of the other experimental blocks in Scratch 2.0, it was a hidden block, meaning it could not be accessed via the block palette. The block is still present in Scratch 3.0 as a hidden block, and its functionality was kept intact. Additionally, the block was renamed to "increment counter", and was moved to the Control category.

Workaround

Main article: List of Block Workarounds

This block's functionality can be simulated with the a single change () by () block:

change [counter v] by (1)

The workaround should be used in conjunction with these two workarounds for the Counter and Clear Counter blocks:

(counter) // Counter workaround

set [counter v] to [0] // Clear Counter workaround

See Also

Cookies help us deliver our services. By using our services, you agree to our use of cookies.