LuaTroid is definitely still at the Technical Demo stage, but I thought I'd throw it up and see if anyone's got flags to throw or wisdom to impart given what's there so far:
http://github.com/MaskedRetriever/LuaTroid
Navigate with w, a, and d keys, tilde key to bring up the tile selector, mouse and drag to draw tiles, and 1 enters debug mode. All the graphics are CC'd so feel free to snag them if my lame blendArt somehow catches your fancy.
*edit: oh and obviously a lot of mechanics such as any kind of collision detection and a screen more than one screen wide are conspicuously absent...
LuaTroid (is only a clone in terms of mechanics)
-
- Prole
- Posts: 22
- Joined: Sat Sep 25, 2010 4:13 pm
- Jasoco
- Inner party member
- Posts: 3726
- Joined: Mon Jun 22, 2009 9:35 am
- Location: Pennsylvania, USA
- Contact:
Re: LuaTroid (is only a clone in terms of mechanics)
The player moves extremely slow. Are you using Delta Time? (dt)
-
- Prole
- Posts: 22
- Joined: Sat Sep 25, 2010 4:13 pm
Re: LuaTroid (is only a clone in terms of mechanics)
Um, yes? dt is probably on the list of things I Don't Know Any Better on. It seems alright on my system but I know I'm not optimizing a lot of things properly yet...
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: LuaTroid (is only a clone in terms of mechanics)
It seems the player moves .2 pixels per frame...
Help us help you: attach a .love.
- Jasoco
- Inner party member
- Posts: 3726
- Joined: Mon Jun 22, 2009 9:35 am
- Location: Pennsylvania, USA
- Contact:
Re: LuaTroid (is only a clone in terms of mechanics)
DT is easy. You just multiply the number of pixels per second * delta time. If you want your player to move 256 pixels in a second do 256 * dt. If you want to do a timer to count down to something else, you do number of seconds * delta time. It's that simple.
What kind of super machine do you have that you don't get any slowdown at all?
What kind of super machine do you have that you don't get any slowdown at all?
-
- Prole
- Posts: 22
- Joined: Sat Sep 25, 2010 4:13 pm
Re: LuaTroid (is only a clone in terms of mechanics)
I think there must be something else wrong as I don't have /that/ great a machine. (It is a quad-core modern machine but it's by no means a gaming rig.) Either I didn't fix the code so it's not regenerating the map every step or there's a version incompatibility I'm missing. I'll run more tests on that soon--
...it sure LOOKS like I have the right code for pasting the whole map to a single image...
I am using dt as the controller for how fast the player moves, so that's not the problem...
...it sure LOOKS like I have the right code for pasting the whole map to a single image...
I am using dt as the controller for how fast the player moves, so that's not the problem...
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: LuaTroid (is only a clone in terms of mechanics)
Not on GitHub you don't.MaskedRetreiver wrote:I am using dt as the controller for how fast the player moves, so that's not the problem...
Help us help you: attach a .love.
-
- Prole
- Posts: 22
- Joined: Sat Sep 25, 2010 4:13 pm
Re: LuaTroid (is only a clone in terms of mechanics)
Okay, first, wow thanks for digging that deep, and second yeah I totally misunderstood how that function works. Definitely on my list for another night's experiments. (Tonight I got to successfully identifying if the player is over a specific tile, paving the way to actually landing on platforms.)
Any other advice on graphics optimization? I've already worked out that I'm going to need to switch to Quads at some point for better render speed on the backdrop, and that I pretty much can never go back to drawing one tile at a time, but beyond that I'm kind of flailing around.
EDIT: Okay that was easier to fix than I thought. Updated version now available on GitHub.
Any other advice on graphics optimization? I've already worked out that I'm going to need to switch to Quads at some point for better render speed on the backdrop, and that I pretty much can never go back to drawing one tile at a time, but beyond that I'm kind of flailing around.
EDIT: Okay that was easier to fix than I thought. Updated version now available on GitHub.
- TechnoCat
- Inner party member
- Posts: 1611
- Joined: Thu Jul 30, 2009 12:31 am
- Location: Milwaukee, WI
- Contact:
Re: LuaTroid (is only a clone in terms of mechanics)
Heh, it doesn't take more than a minute to walk across the room anymore.
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: LuaTroid (is only a clone in terms of mechanics)
You might want to take a look at SpriteBatches, or Framebuffers (0.7.0).MaskedRetreiver wrote: Any other advice on graphics optimization? I've already worked out that I'm going to need to switch to Quads at some point for better render speed on the backdrop, and that I pretty much can never go back to drawing one tile at a time, but beyond that I'm kind of flailing around.
Who is online
Users browsing this forum: No registered users and 0 guests