25 lines
547 B
C++
25 lines
547 B
C++
|
#include <weasel.hpp>
|
||
|
|
||
|
class hello_world : public wsl::app {
|
||
|
public:
|
||
|
void init() override {
|
||
|
wsl::entity::entity e;
|
||
|
hierarchy.root.add_child(e);
|
||
|
hierarchy.root.add_child(e);
|
||
|
hierarchy.root.add_child(e);
|
||
|
hierarchy.root.child_at(0).add_child(e);
|
||
|
|
||
|
renderer.draw_test_triangle();
|
||
|
window.internal_window.get()->setSize(640,480);
|
||
|
}
|
||
|
|
||
|
void update() override {
|
||
|
renderer.draw();
|
||
|
}
|
||
|
};
|
||
|
|
||
|
int main() {
|
||
|
hello_world app;
|
||
|
app.start("Hello World", 640, 480);
|
||
|
return 0;
|
||
|
}
|