Search found 48 matches
- Fri Sep 02, 2011 9:04 pm
- Forum: Support and Development
- Topic: [Solved] Offset turret help
- Replies: 13
- Views: 10054
Re: [Solved] Offset turret help
Why is it low on the priority list? I suppose love is open source so one could just add that feature in, seems to me it would be better to do that than make one in LUA to handle everything. But than the game would not work for anyone who didn't have the special engine. :( Life is full of difficult c...
- Fri Sep 02, 2011 8:35 pm
- Forum: Support and Development
- Topic: [Solved] Offset turret help
- Replies: 13
- Views: 10054
Re: [Solved] Offset turret help
It seems to me this sort of thing would best be implemented within the love engine as compiled code not LUA, any thoughts on that? I also see it as a necessary component of a large game project, I looked around at some of the open source scene graph options but they seemed like complete packages of ...
- Sat Aug 27, 2011 10:25 pm
- Forum: Support and Development
- Topic: [Solved] Offset turret help
- Replies: 13
- Views: 10054
Re: Offset turret help
Well I got this all worked out and I thought I would post the code I used so anyone facing a similar problem might be able to find and use it. dist = math.sqrt(a^2+b^2) if b < 0 then am = -1 elseif b >= 0 then am = 1 end a2 = (math.asin (a / (math.sqrt(a^2 + b^2)))) tx = math.cos((r * am) + a2) * di...
- Mon Aug 08, 2011 9:42 am
- Forum: Support and Development
- Topic: [Solved] Offset turret help
- Replies: 13
- Views: 10054
Re: Offset turret help
when rotating the ship the turret wanders from where it should be. notice how it moves away from where it should be when the ship moves. The turret is offset because there will be groups of 4 turrets, so the x and y values that tell the turret image where to draw need to move around the center of th...
- Mon Aug 08, 2011 8:41 am
- Forum: Support and Development
- Topic: [Solved] Offset turret help
- Replies: 13
- Views: 10054
Re: Offset turret help
I think you misunderstood the problem, I can get stuff to track the mouse, but having the turret offset and still move with the ship is the problem here take a look you will understand when you rotate the ship. this is my first love project and I haven't done any coding before I am sure its a mess =...
- Mon Aug 08, 2011 2:30 am
- Forum: Support and Development
- Topic: [Solved] Offset turret help
- Replies: 13
- Views: 10054
[Solved] Offset turret help
So i have been working on getting turrets to track the mouse. They need to be offset but the offset needs to rotate with the ship =S i tried using the rotated vector but that does not work, anyone have any tips or know of a similar bit of code I can pull apart? t1 = vector(pos.x+50, pos.y+ 50) t1r =...
- Mon Aug 01, 2011 9:42 am
- Forum: Support and Development
- Topic: [Solved] love.filesystem.write problem
- Replies: 5
- Views: 2586
Re: love.filesystem.write problem
ah thanks, I was able to get it to make the file in the appdata/roaming/love/filetest folder. I was thinking the folder would be created in the project folder, D:\love\filetest. it seems inconvenient to send them into the bowls of my hard drive. I'm trying to generate arrays to use in tile maps, and...
- Mon Aug 01, 2011 8:37 am
- Forum: Support and Development
- Topic: [Solved] love.filesystem.write problem
- Replies: 5
- Views: 2586
[Solved] love.filesystem.write problem
I have been trying to get love to create folders or .lua files and it does not seem to work at all. I have tried some code bits I found on the forums, mainly love.filesystem.setIdentity("filetest") love.filesystem.write("test.lua", "love.draw = function() love.graphics.print...