forked from jaildesigner-jailgames/jaildoctors_dilemma
He posat punteros dobles i tampoc va res
This commit is contained in:
@@ -408,13 +408,14 @@ void Resource::renderProgress()
|
||||
Screen::get()->clearSurface();
|
||||
|
||||
auto surface = std::make_shared<Surface>(Screen::get()->getRenderSurfaceData(), 1, 1);
|
||||
auto surface_data = *(Screen::get()->getRenderSurfaceData());
|
||||
const int wired_bar_width = options.game.width - (X_PADDING * 2);
|
||||
SDL_Rect rect_wired = {X_PADDING, bar_position, wired_bar_width, X_PADDING};
|
||||
surface->fillRect(Screen::get()->getRenderSurfaceData(), &rect_wired, stringToColor("blue"));
|
||||
surface->fillRect(surface_data, &rect_wired, stringToColor("blue"));
|
||||
|
||||
const int full_bar_width = wired_bar_width * count_.getPercentage();
|
||||
SDL_Rect rect_full = {X_PADDING, bar_position, full_bar_width, X_PADDING};
|
||||
surface->fillRect(Screen::get()->getRenderSurfaceData(), &rect_full, stringToColor("white"));
|
||||
surface->fillRect(surface_data, &rect_full, stringToColor("white"));
|
||||
|
||||
Screen::get()->renderWithoutNotifier();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user