; Return Example ; -------------- ; Call our damage function for two different attacks Print "The goblin swings a rusty sword ..." Print " Damage dealt: "+Damage(6,8) Print "The knight swings an enchanted axe ..." Print " Damage dealt: "+Damage(25,8) Print "" Print "Press any key to close the example" WaitKey End Function Damage(base,armour) ; Return ends the function at once and hands a value back to the caller If base<=armour Then ; A glancing blow - nothing below this Return runs Return 1 End If Return base-armour End Function