News for hackers. Stuff that matters.
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by xashor on Thursday January 17, 2019 @05:04PM (#18935101)
I use it for playing around with some game ideas, really liked the ease of it. Clean, compact API.

Only nuisance is that SUPPORT_BUSY_WAIT_LOOP is defined in the defaults, so I can't use the package from my distribution but have to compile it myself – as I don't want 100% CPU usage when prototyping (where I can happily live with inaccuracies of the timers). I considered opening an issue and forgot about it. But you, Ray, seem to be reading this thread anyway. :-) Thanks, by the way!

Re:Raylib: a simple and easy-to-use library to enjoy game pr... by raysan5 on Thursday January 17, 2019 @05:15PM (#18935178)
Hey, yeah, actually there have been a couple of issues about it... Using a busy wait loop is the only way to keep a quite stable timming measure, depending on OS, clock granularity could be up to 10 ms (despite raylib tries to enable a hi-res clock with granularity of 1ms), it means, some undesired timming issues...

In any case, you can just comment that line in src/config.h (or even uncomment SUPPORT_EVENTS_WAITING) and recompile the lib. raylib has been designed with customization in mind.

Re:Raylib: a simple and easy-to-use library to enjoy game pr... by ArtWomb on Thursday January 17, 2019 @03:44PM (#18934440)
Loving the minimal aesthetic. Will give it a try this weekend ;)

Full API:

https://www.raylib.com/cheatsheet/cheatsheet.html

Re:Raylib: a simple and easy-to-use library to enjoy game pr... by raysan5 on Thursday January 17, 2019 @04:51PM (#18934989)
Actually cheatsheet is a bit outdated, raylib is growing fast, several functions have been added in latest version 2.4-dev, you can check current API directly in raylib.h: https://github.com/raysan5/raylib/blob/master/src/raylib.h
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by potiuper on Thursday January 17, 2019 @10:38PM (#18936842)
Prefer the use of types over preprocessor defines - ex: static const vs #define PI, RAD2DEG, etc. (https://github.com/raysan5/raylib/blob/master/src/raymath.h). Also, take a look at using the GLSL data types for vectors and matrices - https://www.khronos.org/opengl/wiki/Data_Type_(GLSL) along with explicit use of SSE when appropriate and supported.
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by thepete2 on Thursday January 17, 2019 @05:35PM (#18935326)
Could you use this for bigger projects? Or would I run into (performance?) problems and have to port the project to another engine?
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by raysan5 on Friday January 18, 2019 @04:10AM (#18938040)
raylib is not an engine. It's a quite low level library intended to enjoy coding, probably better small games. You can use for a big project but it lacks lots of required elements that engines have, to name some: Screen Manager, Content Manager, Objects Manager. In any case, you can test it and evaluate if it could fit your needs.
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by jpfed on Thursday January 17, 2019 @04:25PM (#18934801)
>Bindings to Lua (raylib-lua), Go (raylib-go) and more!

Is there a list of other bindings somewhere? I didn't see one in my admittedly cursory look.

Re:Raylib: a simple and easy-to-use library to enjoy game pr... by raysan5 on Thursday January 17, 2019 @04:48PM (#18934966)
yes, actually there are bindings to +15 languages, here it is a list: https://github.com/raysan5/raylib/blob/master/CONTRIBUTING.m...
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by jpfed on Thursday January 17, 2019 @10:41PM (#18936852)
Cool, thanks!
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by lbj on Thursday January 17, 2019 @06:14PM (#18935573)
Looks awesome, but unfortunately a few of the examples don't work for me. Is Firefox not supported?
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by raysan5 on Friday January 18, 2019 @04:06AM (#18938022)
Web examples are not updated, still using raylib 1.8. But all should work on any browser, which ones fail on Firefox?
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by dlivingston on Thursday January 17, 2019 @06:34PM (#18935696)
Very cool - the syntax reminds me of Blitz3D, the language of choice for 15 year old me :)

Does this work with Swift and iOS - namely, is embedding this library as a dependency likely to pass Apple's App Store review process?

Re:Raylib: a simple and easy-to-use library to enjoy game pr... by raysan5 on Friday January 18, 2019 @04:05AM (#18938016)
Sorry, no iOS support, it can be ported but I don't have an iOS or a MAC. raylib is plain C and uses OpenGL, lately Apple ecosystem doesn't like those techs.
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by azhenley on Thursday January 17, 2019 @11:01PM (#18936934)
Looks fun! I have been moving towards using Go for everything so this might be a good excuse for me to figure out how to use C libraries.
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by genjipress on Thursday January 17, 2019 @03:15PM (#18934172)
Sorry, but this site is illegible on mobile.
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by raysan5 on Thursday January 17, 2019 @04:53PM (#18935001)
Sorry, already working on an updated web.
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by zerr on Friday January 18, 2019 @05:34AM (#18938364)
What would be the similar cross-platform (including mobile) lib in C++?
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by 75dvtwin on Saturday January 19, 2019 @11:16PM (#18951024)
I think this library, is exactly that. Cross platform in (C), and works on mobile, browsers, as well as desktop environments.
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by zerr on Tuesday January 29, 2019 @05:01AM (#19025138)
Yes, but I'd prefer something similar in C++, not C :)
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by sandov on Saturday February 09, 2019 @05:40PM (#19125146)
SFML is great and has a rather big community.
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by jteppinette on Thursday January 17, 2019 @03:23PM (#18934246)
Does anyone know how the C code is ported to the web in the examples?
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by VikingCoder on Thursday January 17, 2019 @04:49PM (#18934973)
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by raysan5 on Thursday January 17, 2019 @04:53PM (#18934999)
yes, emscriptem, compiled to WASM... but current web examples are still asm.js. Web needs some update...
[dead]
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by justinclift on Thursday January 17, 2019 @10:39PM (#18936847)
"ethical advertising"? Example?
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by cavneb on Friday January 18, 2019 @12:11AM (#18937191)
We don’t use cookies. Our code is open source. our ads are relevant to developers. 50-65% of the revenue goes to the publishers (devs). Examples at codesandbox.io, JSBin.com, phaser.io
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by justinclift on Friday January 18, 2019 @08:58AM (#18939297)
No worries, thanks for the clarification.

It does sound far less shady than other places.

I wouldn't call that good enough to make for "ethical" advertising, but I understand you need a handle to hang your brand on.

Re:Raylib: a simple and easy-to-use library to enjoy game pr... by cavneb on Friday January 18, 2019 @03:18PM (#18942638)
What aspect would you consider unethical, or insufficient to make it ethical?
Re:Raylib: a simple and easy-to-use library to enjoy game pr... by justinclift on Saturday January 19, 2019 @01:25AM (#18945639)
It's advertising.