Pixel House Idle / Offline Rewards

:stopwatch: Pixel House Idle / Offline Rewards – Extension for GDevelop

Hi everyone! :waving_hand:

I recently created a new GDevelop extension for idle, tycoon, production, farming and management games:

Pixel House Idle / Offline Rewards

The basic idea is very simple:

Create something that produces a resource over time – and let the extension handle the time calculation, even while the game is closed.

:pick: Simple example

Imagine your game has a quarry:

Quarry β†’ 100 Stone per day

The player closes the game and comes back 3 days later.

The quarry has produced:

300 Stone

No timers need to keep running in the background. The extension calculates the elapsed real-world time when the player returns.

:taxi: Every producer has its own timer

This was one of the main reasons I created the extension.

For example:

Taxi 1 is purchased at 12:00
Taxi 2 is purchased at 15:00

Both earn $300 per hour.

If the player returns at 18:00:

Taxi 1 β†’ $1,800
Taxi 2 β†’ $900

Each producer has its own independent timestamp, so newly purchased producers don’t receive rewards for time before they existed.

:factory: What is a β€œProducer”?

Basically, anything you want!

:taxi: Taxi β†’ Money
:pick: Quarry β†’ Stone
:evergreen_tree: Lumber Mill β†’ Wood
:sheaf_of_rice: Farm β†’ Crops
:chicken: Chicken Coop β†’ Eggs
:factory: Factory β†’ Products
:pick: Mine β†’ Ore
:high_voltage: Solar Panel β†’ Energy

The extension only calculates a number, so you decide what that number represents.

:chart_increasing: Upgrades are possible too

Let’s say your quarry produces:

100 Stone per day

The player assigns another worker to it.

Simply change its income to:

200 Stone per day

The reward already accumulated before the upgrade is preserved.

:pause_button: Pause & Resume

Individual producers can also be paused.

For example, if a machine is switched off:

Pause Producer β€œMachine_01”

Its current reward is preserved, but it stops producing.

Later:

Resume Producer β€œMachine_01”

Production continues from that moment. The time spent paused is not counted.

The pause state is persistent as well, so closing and reopening the game won’t accidentally generate rewards for a paused producer.

:star: Main features

  • Independent timer for every producer

  • Offline progress while the game is closed

  • Money, resources, crops, materials, energy, etc.

  • Individual and total reward calculation

  • Claim individual rewards or all rewards

  • Change production rates at runtime

  • Pause & resume individual producers

  • Maximum offline time

  • Reset and remove producers

  • Conditions for producer/reward states

  • Expressions for rewards, elapsed time, income and intervals

  • Persistent saved producer data

  • Commented GDevelop example project included

No JavaScript knowledge is required to use it.

I originally created this after a request for an idle tycoon system where every purchased vehicle needed its own independent offline timer, but while developing it I realized the same system can be useful for many other types of games too.

I hope some of you find it useful! :slightly_smiling_face:

Pixel House Idle / Offline Rewards v1.0.1

https://markusschuetz.itch.io/pixel-house-idle-offline-rewards