Closed Augusto-Fadanelli closed 3 years ago
The helper class for Rectangle was added here so I think it's not in the released jar. https://github.com/electronstudio/jaylib/commit/c2546ad991fe6e3e072600d9a3d43108d27d46c5
You could copy and paste the code from there into your project, or you could wait until I release a new jar.
actually if you're copy and pasting, use this version https://github.com/electronstudio/jaylib/blob/master/src/com/raylib/Jaylib.java
the file "com/raylib/Raylib.java" does not exist, do I need to create it to build? How I do it? thanks for your patience
I'm currently thinking the best way is just to do:
this.teste = new Rectangle().x(0.0f).y(0.0f).width(64.0f).height(64.0f);
To discuss if it would be better to use helper classes go to #1
I'm thinking the helpers are not actually a good idea, because they make it easy to think you're dealing with Java objects, when actually these are chunks of memory allocated on the native heap. The GC behaviour is different and the JVM won't be able to do boxing, escape analyse, etc, optimizations on them. The unusual syntax helps to remind me of that.
But anyway the helpers are still there.
when i use and compile:
this.teste = new Rectangle(0.0f, 0.0f, 64.0f, 64.0f);
I receive this:
i didn't build jaylib and i running it in windows 7 x64