Search found 82 matches

by parallax7d
Sun Aug 17, 2014 2:28 am
Forum: Support and Development
Topic: First game, struggling with camera/movement
Replies: 7
Views: 4573

Re: First game, struggling with camera/movement

MadByte YOU ROCK!!! thanks so much! :ultrahappy:
by parallax7d
Sat Aug 16, 2014 12:48 am
Forum: Support and Development
Topic: First game, struggling with camera/movement
Replies: 7
Views: 4573

Re: First game, struggling with camera/movement

I'm printing out the camera coordinates like you suggested, and they seem to change with the s key. But nothing on the screen moves. I feel like I'm missing some basic thing. Here's the code, and I'll attach a .love which illustrates the issue function love.load() Camera = require "lib.camera&q...
by parallax7d
Fri Aug 15, 2014 7:30 pm
Forum: Support and Development
Topic: First game, struggling with camera/movement
Replies: 7
Views: 4573

Re: First game, struggling with camera/movement

Sorry, just a typo when I was writing out the question. In my code it's correct. I can run the game, get no error messages, but pressing the keys does nothing.
by parallax7d
Fri Aug 15, 2014 1:06 pm
Forum: Support and Development
Topic: First game, struggling with camera/movement
Replies: 7
Views: 4573

First game, struggling with camera/movement

Basic question on how to move the camera around. Using hump camera. Here is what I have so far. Pressing "d" or "s" doesn't move anything. Also, cam doesn't seem to want to "start" at coordinates 100, 100 for some reason, but I don't get an error. function love.load() C...
by parallax7d
Mon Aug 11, 2014 2:17 pm
Forum: Support and Development
Topic: hump camera return
Replies: 1
Views: 1071

hump camera return

The last block of code from the hump.camera module: -- the module return setmetatable({new = new}, {__call = function(_, ...) return new(...) end}) I'm fairly new to OOP and metatables, and can't parse what the point of this code is. So it's returning a table with the new method defined in it..and t...
by parallax7d
Tue Aug 05, 2014 9:06 pm
Forum: Support and Development
Topic: Need to change image each frame
Replies: 6
Views: 3940

Re: Need to change image each frame

Just to clarify, so when we use love.graphics.newImage, is it not caching anything into system ram, it's uploading directly to the vram?
by parallax7d
Tue Aug 05, 2014 4:51 pm
Forum: Support and Development
Topic: Need to change image each frame
Replies: 6
Views: 3940

Re: Need to change image each frame

Is there any way for love to display an image from a memory region of my choosing? I'm assuming it's caching a copy on it's own? I would rather it just reference mine directly if possible.
by parallax7d
Tue Aug 05, 2014 4:33 pm
Forum: Support and Development
Topic: Need to change image each frame
Replies: 6
Views: 3940

Re: Need to change image each frame

Unfortunately for my needs that method would be too slow like you said. The image:refresh() method looks promising though! It seems to be working at least 100x faster than a full graphics.newImage call. thanks!
by parallax7d
Tue Aug 05, 2014 3:07 pm
Forum: Support and Development
Topic: Need to change image each frame
Replies: 6
Views: 3940

Need to change image each frame

I need to generate an image, and render it each frame. This is for a particle simulation with lots of moving pixels. I put love.graphics.newImage under love.update and while it did reload the image each frame, it was at an unusable framerate. Would it be possible to load a new image once - then mani...
by parallax7d
Thu Jul 31, 2014 8:05 pm
Forum: Support and Development
Topic: Favorite way to store next loop state?
Replies: 4
Views: 2047

Re: Favorite way to store next loop state?

I was thinking about that, but if the condition results change literally every frame, it ends up being option a roughly 50% of the time, and option b 50% of the time. Won't that royally screw up any sort of branch prediction the cpu is trying to do? Is there a way to toggle the tables without using ...