[examples] Fix examples to work in MSVC (#5267)

* Fix warnings in many examples
Add examples to MSVC solution correctly

* fix CI error

---------

Co-authored-by: Ray <raysan5@gmail.com>
This commit is contained in:
Jeffery Myers
2025-10-15 10:02:52 -07:00
committed by GitHub
parent e3a562ab57
commit 7191749d66
34 changed files with 1550 additions and 405 deletions

View File

@@ -252,7 +252,11 @@ int main()
// Draw spheres to show the lights positions
for (int i = 0; i < MAX_LIGHTS; i++)
{
Color lightColor = (Color){ lights[i].color[0]*255, lights[i].color[1]*255, lights[i].color[2]*255, lights[i].color[3]*255 };
Color lightColor = (Color){
(unsigned char)(lights[i].color[0]*255),
(unsigned char)(lights[i].color[1] * 255),
(unsigned char)(lights[i].color[2] * 255),
(unsigned char)(lights[i].color[3] * 255) };
if (lights[i].enabled) DrawSphereEx(lights[i].position, 0.2f, 8, 8, lightColor);
else DrawSphereWires(lights[i].position, 0.2f, 8, 8, ColorAlpha(lightColor, 0.3f));