Add a layer for game characters.
This commit is contained in:
parent
b60bbf3739
commit
be56c55e3e
3 changed files with 5 additions and 3 deletions
|
@ -119,7 +119,7 @@ namespace curry {
|
|||
item.source = source_rect();
|
||||
item.destination = destination_rect(parViewport.position());
|
||||
item.texture = texture();
|
||||
parDQ.add_for_rendering(DrawaLayerNames::Background, std::move(item));
|
||||
parDQ.add_for_rendering(DrawaLayerNames::Characters, std::move(item));
|
||||
assert(not item.texture);
|
||||
}
|
||||
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
namespace curry {
|
||||
BETTER_ENUM(DrawaLayerNames, uint16_t,
|
||||
Background,
|
||||
Debug
|
||||
);
|
||||
Debug,
|
||||
Characters
|
||||
)
|
||||
} //namespace curry
|
||||
|
|
|
@ -83,6 +83,7 @@ namespace curry {
|
|||
inp.AddAction(ActionDown, Key(InputDevice_Keyboard, SDL_SCANCODE_DOWN), "Move down");
|
||||
|
||||
add_layer_assert_done(drawing_queue(), DrawaLayerNames::Background);
|
||||
add_layer_assert_done(drawing_queue(), DrawaLayerNames::Characters);
|
||||
#if !defined(NDEBUG)
|
||||
add_layer_assert_done(drawing_queue(), DrawaLayerNames::Debug);
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue