Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
963a178
Update raylib_api.json with new parser for 4.0.0
RobLoach May 12, 2022
8eae267
Bring in @raylib/api
RobLoach May 12, 2022
708222f
Update the parser
RobLoach May 12, 2022
adb1790
Update definitions
RobLoach May 12, 2022
52ee4bd
Rebuild the code
RobLoach May 12, 2022
aa3d608
Add raymath
RobLoach May 12, 2022
2e4e175
Update code
RobLoach May 12, 2022
16eea24
Fix model exmaple
RobLoach May 12, 2022
77fa8ae
Coding standard
RobLoach May 12, 2022
15b41e5
Consider the arrays as pointers
RobLoach May 12, 2022
d7fa739
Ignore the complicated structs for now
RobLoach May 12, 2022
0db664e
Ignore codignn standards
RobLoach May 12, 2022
05218b4
Remove small diff changes
RobLoach May 12, 2022
05b1e4e
Merge branch 'api-docs' of github.com:RobLoach/node-raylib into parser
RobLoach May 16, 2022
87b9fb4
Merge branch 'master' of github.com:RobLoach/node-raylib into parser
RobLoach May 16, 2022
9b06d3e
Comment out the standard code style tests for now
RobLoach May 19, 2022
6648f73
Merge branch 'master' of github.com:RobLoach/node-raylib into parser
RobLoach Jun 1, 2022
59dfdc8
Merge branch 'parser' of github.com:RobLoach/node-raylib into parser
RobLoach Jun 1, 2022
f0c2bb1
Update tools/generate_templates/node-raylib-bindings.js
RobLoach Jun 11, 2022
167b578
Merge branch 'master' of github.com:RobLoach/node-raylib into parser
RobLoach Jun 13, 2022
998fe10
Add raygui
RobLoach Jul 30, 2022
1331917
Fix coding styles
RobLoach Jul 30, 2022
e3f1d16
Fix BoneInfo definition
RobLoach Jul 30, 2022
a542777
setting both BoneInfo fields to char makes it build
konsumer Aug 5, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
876 changes: 595 additions & 281 deletions docs/API.md

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions examples/models/models_rlgl_solar_system.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ camera.target = r.Vector3(0, 0, 0)
camera.up = r.Vector3(0, 1, 0)
camera.fovy = 45
camera.type = r.CAMERA_PERSPECTIVE
camera.projection = r.CAMERA_PERSPECTIVE

r.SetCameraMode(camera, r.CAMERA_FREE)

Expand Down
68 changes: 68 additions & 0 deletions examples/raygui/raygui_basic_window.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
/*******************************************************************************************
*
* raylib [raygui] example - Basic window
*
* raylib is licensed under an unmodified zlib/libpng license (View raylib.h for details)
*
* Copyright (c) 2022 Rob Loach (@RobLoach)
*
********************************************************************************************/

const r = require('raylib')

// Initialization
// --------------------------------------------------------------------------------------
const screenWidth = 800
const screenHeight = 450
let showMessageBox = false
let backgroundColor = r.RAYWHITE

r.InitWindow(screenWidth, screenHeight, 'raylib [raygui] example - basic window')

r.SetTargetFPS(60)

// r.GuiLoadStyleDefault()
// --------------------------------------------------------------------------------------

// Main game loop
while (!r.WindowShouldClose()) { // Detect window close button or ESC key
// Update
// ----------------------------------------------------------------------------------
// TODO: Update your variables here
// ----------------------------------------------------------------------------------

// Draw
// ----------------------------------------------------------------------------------
r.BeginDrawing()

r.ClearBackground(backgroundColor)

if (r.GuiButton(r.Rectangle(30, 100, 200, 30), 'Change Background Color')) {
showMessageBox = true
}

if (showMessageBox) {
switch (r.GuiMessageBox(r.Rectangle(r.GetScreenWidth() / 2 - 200, r.GetScreenHeight() / 2 - 50, 400, 100), 'Change Background Color', 'Do you really want to change the background?', 'Yes;No')) {
case 0:
case 2:
showMessageBox = false
break
case 1: // Yes
backgroundColor = r.Color(
r.GetRandomValue(0, 255),
r.GetRandomValue(0, 255),
r.GetRandomValue(0, 255),
255
)
showMessageBox = false
}
}

r.EndDrawing()
// ----------------------------------------------------------------------------------
}

// De-Initialization
// --------------------------------------------------------------------------------------
r.CloseWindow() // Close window and OpenGL context
// --------------------------------------------------------------------------------------
13 changes: 13 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@
"module-alias": "^2.2.2"
},
"devDependencies": {
"@raylib/api": "^4.0.0",
"archiver": "^5.3.1",
"jest": "^28.1.0",
"jsdoc-to-markdown": "^7.1.1",
Expand Down
Loading