feat: Print using log.c

This commit is contained in:
2025-11-06 11:03:21 +13:00
parent ced85f0e53
commit 60f56f9609
2 changed files with 3 additions and 1 deletions

View File

@@ -7,5 +7,6 @@ void Update(float dt) {
}
void Draw() {
Print("Drawing stuff");
DrawText("Hello from AngelScript - Working perfectly!", int(x), int(y), 20, 0xFF0000FF);
}

View File

@@ -2,6 +2,7 @@
#include "raylib.h"
#include <iostream>
#include <assert.h>
#include "log/log.h"
void ScriptBindings::RegisterAll(asIScriptEngine* engine) {
// Register Print function
@@ -16,7 +17,7 @@ void ScriptBindings::RegisterAll(asIScriptEngine* engine) {
}
void ScriptBindings::Print(const std::string &msg) {
std::cout << "[Script] " << msg << std::endl;
log_info("%s", msg.c_str());
}
Color ColorFromUInt(unsigned int c) {