-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Working on VSCode
JUJHKJHLjk edited this page May 10, 2025
·
1 revision
#include "raylib.h"
int main() { InitWindow(800, 600, "DustRunner - Ball Adventure");
Camera3D camera = { 0 };
camera.position = { 4.0f, 2.0f, 4.0f };
camera.target = { 0.0f, 0.0f, 0.0f };
camera.up = { 0.0f, 1.0f, 0.0f };
camera.fovy = 45.0f;
camera.projection = CAMERA_PERSPECTIVE;
SetCameraMode(camera, CAMERA_FREE);
SetTargetFPS(60);
while (!WindowShouldClose()) {
UpdateCamera(&camera);
BeginDrawing();
ClearBackground(RAYWHITE);
BeginMode3D(camera);
DrawSphere((Vector3){ 0.0f, 1.0f, 0.0f }, 1.0f, BLUE); // The ball
DrawPlane((Vector3){ 0.0f, 0.0f, 0.0f }, (Vector2){ 50.0f, 50.0f }, BEIGE); // Ground
DrawGrid(20, 1.0f);
EndMode3D();
DrawText("Travel as far as you can!", 10, 10, 20, DARKGRAY);
EndDrawing();
}
CloseWindow();
return 0;
}
www.raylib.com | itch.io | GitHub | Discord | YouTube
- Architecture
- Syntax analysis
- Data structures
- Enumerated types
- External dependencies
- GLFW dependency
- libc dependency
- Platforms and graphics
- Input system
- Default shader
- Custom shaders
- Coding conventions
- Integration with other libs
- Working on Windows
- Working on macOS
- Working on GNU Linux
- Working on Chrome OS
- Working on FreeBSD
- Working on Raspberry Pi
- Working for Android
- Working for Web (HTML5)
- Working on exaequOS Web Computer
- Creating Discord Activities
- Working anywhere with CMake
- CMake Build Options
- raylib templates: Get started easily
- How To: Quick C/C++ Setup in Visual Studio 2022, GCC or MinGW
- How To: C# Visual Studio Setup
- How To: VSCode
- How To: Eclipse
- How To: Sublime Text
- How To: Code::Blocks