The Implements IDrawableBatch tells the FlatRedBall Editor to generate code for custom rendering including:
All necessary properties for the IDrawableBatch interface
Empty implementation for IDrawableBatch.Update and IDrawableBatch.Destroy. These are are empty since entities already have update and destroy methods.
Addition of the entity to the SpriteManager as an IDrawableBatch
Removal of the entity to the SpriteManager as an IDrawableBatch
Setting ImplementsIDrawableBatch to true does not result in code generation writing a Draw method implementation, so this must be implemented in custom code.
The following instructions show how to use the ImplementsIDrawableBatch property to create an entity which is drawn using the SpriteBatch class. Before writing code, the following steps are needed to create an IDrawableBatch entity:
Create an Entity, or select an existing entity which should have is own Draw method
Set the Entity's ImplementsIDrawableBatch property to True
Add a .png file to the entity. This will be used in the Draw call
Once the entity has been created, we must define a Draw call in the entity's code file. Notice that the Draw method has a Camera parameter. This allows entities to perform rendering relative to the current Camera. In this example the entity ignores the Camera for simplicity.
For more information and code samples related to IDrawableBatch, see the IDrawableBatch page.