[SOLVED] Help with run for gold

How do I check if an item has value?

def onCollect(event):
    item = event.other
    # If the item has a "value" property:
    if item.value:
        # Increase the game score by item's value:
        game.score += item.value

Please check the name again. I cannot find any level called, “run for gold.”

It’s here: https://codecombat.com/play/level/run-for-gold

1 Like

That’s right I think.

Aaaaah. I see. Game Development section. That’s why I didn’t recognize it.

1 Like