AudioAsset
Ease
FastString
FontAsset
NineSlice
PackedSprite
PackedSpriteID
RB
   HardwareSettings
   IRetroBlitGame
RBAsset
Rect2i
ShaderAsset
SoundReference
SpriteGrid
SpriteSheetAsset
TMXMapAsset
   TMXLayer
   TMXLayerLoadState
   TMXObject
   TMXObjectGroup
   TMXProperties
Vector2i

RB.Game

Property  -  Static Read Only

Type

IRetroBlitGame

Description

A reference to the current IRetroBlitGame game instance running under RetroBlit. This is the same instance that is passed to RetroBlit by the call into the RB.Initialize method.

This is a convenience method which allows the caller to get a reference to their game from anywhere.

Example

void Update()
{
    var game = (MyGame)RB.Game;

    if (!game.player.dead) {
        game.player.score++;
    }
}

See Also

RB.Initialize
IRetroBlitGame