6 ms·
Raylib: a simple and easy-to-use library to enjoy game programming
- genjipress 8y agoSorry, but this site is illegible on mobile.
- raysan5 8y agoSorry, already working on an updated web.
- jteppinette 8y agoDoes anyone know how the C code is ported to the web in the examples?
- VikingCoder 8y agoLooks like emscripten: https://github.com/raysan5/raylib/blob/master/games/Makefile https://github.com/raysan5/raylib/blob/master/games/Makefile
- raysan5 8y agoyes, emscriptem, compiled to WASM... but current web examples are still asm.js. Web needs some update...
- ArtWomb 8y agoLoving the minimal aesthetic. Will give it a try this weekend ;) Full API: https://www.raylib.com/cheatsheet/cheatsheet.html https://www.raylib.com/cheatsheet/cheatsheet.html
- raysan5 8y agoActually 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 https://github.com/raysan5/raylib/blob/master/src/raylib.h
- jpfed 8y ago>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.
- xashor 8y agoI 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!
- raysan5 8y agoHey, 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.
- thepete2 8y agoCould you use this for bigger projects? Or would I run into (performance?) problems and have to port the project to another engine?
- raysan5 8y agoraylib 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.
- lbj 8y agoLooks awesome, but unfortunately a few of the examples don't work for me. Is Firefox not supported?
- raysan5 8y agoWeb examples are not updated, still using raylib 1.8. But all should work on any browser, which ones fail on Firefox?
- dlivingston 8y agoVery 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?
- raysan5 8y agoSorry, 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.
- cavneb 8y agoPlease check out codefund.app. We help sustain open source projects through ethical advertising. We have recently been helping more game-related projects such as yours. Disclaimer: I am the founder of CodeFund.
- justinclift 8y ago"ethical advertising"? Example?
- cavneb 8y agoWe 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
- justinclift 8y agoNo 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.
- cavneb 8y agoWhat aspect would you consider unethical, or insufficient to make it ethical?
- justinclift 8y agoIt's advertising.
- potiuper 8y agoPrefer 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 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) https://www.khronos.org/opengl/wiki/Data_Type_(GLSL) along with explicit use of SSE when appropriate and supported.
- azhenley 8y agoLooks 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.
- zerr 8y agoWhat would be the similar cross-platform (including mobile) lib in C++?