mirror of
https://github.com/zoriya/Bomberman.git
synced 2025-12-21 05:45:10 +00:00
import all assets
This commit is contained in:
@@ -28,7 +28,7 @@ const std::vector<std::string>textures = {
|
||||
|
||||
std::string get_full_path(const std::string &color)
|
||||
{
|
||||
std::string path = "assets/player_";
|
||||
std::string path = "assets/player/";
|
||||
|
||||
path += color;
|
||||
path += ".png";
|
||||
@@ -42,21 +42,21 @@ int main()
|
||||
const int screenWidth = 800;
|
||||
const int screenHeight = 450;
|
||||
std::vector<std::string>::const_iterator iterator = textures.begin();
|
||||
const std::string modelPath = "assets/player.obj";
|
||||
const std::string texturePath = "assets/player_blue.png";
|
||||
const std::string modelPath = "assets/player/player.obj";
|
||||
const std::string texturePath = "assets/player/blue.png";
|
||||
//const std::string animationPath = "assets/guy.iqm";
|
||||
RAY::TraceLog::setLevel(LOG_WARNING);
|
||||
RAY::Window &window = RAY::Window::getInstance(screenWidth, screenHeight, "Bidibidibop", FLAG_WINDOW_RESIZABLE);
|
||||
RAY::Image icon("assets/icon.png");
|
||||
window.setIcon(icon);
|
||||
RAY::Model model(modelPath);
|
||||
RAY::Camera::Camera3D camera(RAY::Vector3(10.0f, 10.0f, 10.0f),
|
||||
RAY::Vector3(0.0f, 0.0f, 0.0f),
|
||||
RAY::Vector3(0.0f, 1.0f, 0.0f),
|
||||
45.0f, CAMERA_PERSPECTIVE
|
||||
);
|
||||
RAY::Model model(modelPath);
|
||||
RAY::Image icon("assets/bomberman.ico");
|
||||
RAY::Texture texture(get_full_path(*iterator));
|
||||
window.setIcon(icon);
|
||||
//RAY::ModelAnimations animations(animationPath);
|
||||
//RAY::ModelAnimations animations(modelPath);
|
||||
RAY::Drawables::Drawables3D::Grid grid(10, 1.0f);
|
||||
RAY::Drawables::Drawables2D::Text instructionText("PRESS SPACE to PLAY MODEL ANIMATION", 10, {10, 20} , MAROON);
|
||||
model.setTextureToMaterial(MAP_DIFFUSE, texture);
|
||||
|
||||
Reference in New Issue
Block a user