WARNING: IT'S PROBABLY IMPOSSIBLE FOR YOU TO RUN THIS
I'm busy tomorrow afternoon so I decided to do clik of the month tonight! And I can't run klik n play so I decided to try to make a game in LUA with Polycode because I have not written a program in LUA before. I started at 9:19 PM. At 10:22 PM I built and checked in the version attached as LuaTest.polyapp above. I then spent the next hour attempting to change the player object from a square to a triangle, then discovering that due to bugs in Polycode (it's pretty new) it is not possible to make a triangle in LUA right now, then filing bug reports against Polycode. I never got any further than the 10:22 version. I had been trying to implement Asteroids.
But I DID FINISH THIS ONE FILE WITHIN THE TWO HOUR LIMIT so here you go.
In order to run the attached polyapp file:
- Go to http://polycode.org, click "Downloads"
- Download "Polycode Player ONLY" for the appropriate operating system.
- Open the Polyapp file using the Polycode Player.
- It will immediately crash.
In other words: YOU CAN'T RUN THIS IT'S BROKEN. I have no idea why but the .polyapp works with the version of PolyCode Player I built myself and have on my laptop here, but doesn't work with the official version of PolyCode Player, even though they ought to be the same. This Lua stuff is hard :(
Since you can't play this unless you are in the same building as me, I suggest looking at the screen shot and pretending that you are pressing the arrow keys and it's making the little black rectangle zoom around and all the little rectangle things are bouncing off it and when you hold up and right you just zoom faster and faster, imparting momentum on all the little rectangles, until they're gliding around and bouncing off each other like broken glass suspended in air.
ps here's the source code, the uploaded version is revision bc2833073e00
https://bitbucket.org/runhello/luatest
Comments
I got the message "Error on
I got the message "Error on line 50.000000 - attempt to call global 'PhysicsScreen' (a nil value)". Does that count as "immediately crash"?
Ooh
That's interesting-- what OS are you on?
I think in both my case (it crashes) and your case (nil PhysicsScreen) the root cause is the same thing, "the Polycode physics module is not being correctly loaded".
Windows Vista 64-bit.
Windows Vista 64-bit. D-Don't judge me! ;_;
heh
I'm running 32-bit vista. (with 16-bit support!)
Sure it's pretty shit but I'm familiar with it now and it still does everything I need.
That must be a weird copy of
That must be a weird copy of Lua or something. I don't think I've ever seen Lua spit out error line numbers as floating point.
Also, I love how despite the fact that they're using tech available on/originating from Linux, the Linux version of PolyCode is still "coming soon" (GLORIOUS LOVE2D MASTER RACE).
Well
Actually from my experiments Polycode works on Linux now if you compile from source, there's just not been a downloadable package for it yet...
The downloadable version on the site is a bit behind what's on github.