| 108 | } |
| 109 | |
| 110 | void Draw(Bitmap& dst) override { |
| 111 | if (!bitmap) { |
| 112 | return; |
| 113 | } |
| 114 | |
| 115 | const Game_Pictures::Picture* pic = Main_Data::game_pictures->GetPicturePtr(pic_id); |
| 116 | if (!pic) { |
| 117 | return; |
| 118 | } |
| 119 | const Sprite_Picture* sprite = pic->sprite.get(); |
| 120 | if (!sprite) { |
| 121 | return; |
| 122 | } |
| 123 | |
| 124 | // For unknown reasons the official plugin has an y-offset of 2 |
| 125 | if (fixed) { |
| 126 | dst.Blit(x - Game_Map::GetDisplayX() / 16, y - Game_Map::GetDisplayY() / 16 + 2, *bitmap, bitmap->GetRect(), sprite->GetOpacity()); |
| 127 | } else { |
| 128 | dst.Blit(x, y + 2, *bitmap, bitmap->GetRect(), sprite->GetOpacity()); |
| 129 | } |
| 130 | }; |
| 131 | |
| 132 | void Update() { |
| 133 | if (GetZ() == 0) { |
nothing calls this directly
no test coverage detected