| 190 | } |
| 191 | |
| 192 | void SpriteRender::OnEndPlay() |
| 193 | { |
| 194 | // Base |
| 195 | Actor::OnEndPlay(); |
| 196 | |
| 197 | // Release material instance |
| 198 | if (_materialInstance) |
| 199 | { |
| 200 | _materialInstance->SetBaseMaterial(nullptr); |
| 201 | _materialInstance->Params.Resize(0); |
| 202 | _materialInstance->RemoveReference(); |
| 203 | _materialInstance = nullptr; |
| 204 | } |
| 205 | } |
| 206 | |
| 207 | void SpriteRender::OnEnable() |
| 208 | { |
nothing calls this directly
no test coverage detected