Search found 11 matches
- Sat Apr 16, 2016 11:43 pm
- Forum: Support and Development
- Topic: States for menus and such
- Replies: 4
- Views: 3157
Re: States for menus and such
Thank you A LOT! Im still quite new to lua and love (and i guess programming in general) so thank you for your help and explaining whats going on. I will try to implement a better states system when I have the time.
- Sat Apr 16, 2016 4:16 pm
- Forum: Support and Development
- Topic: Changing key bindings
- Replies: 2
- Views: 2442
Changing key bindings
What would be the best way to go about allowing the player to change their keybindings?
I had the idea of using a text file and reading the bindings from that but im wondering if there are smarter ways to go about this (there probably are).
Could anyone help?
I had the idea of using a text file and reading the bindings from that but im wondering if there are smarter ways to go about this (there probably are).
Could anyone help?
- Sat Apr 16, 2016 3:24 pm
- Forum: Support and Development
- Topic: States for menus and such
- Replies: 4
- Views: 3157
Re: States for menus and such
Could anyone help please? Im using his states file to go into my game, then when i try to go back to the menu its just a black screen and I dont know how to fix it. Could anyone help?
- Fri Apr 15, 2016 3:34 pm
- Forum: Support and Development
- Topic: States for menus and such
- Replies: 4
- Views: 3157
States for menus and such
Hi i'm using goature's states tutorial to base a states system for my game and it works as in i can go from the menu into the game. But when i try to loadState back into the menu i just get a blank screen. What im wondering is if someone could explain his states main.lua file in his video so that I ...
- Mon Apr 11, 2016 3:28 pm
- Forum: Support and Development
- Topic: Collision with walls
- Replies: 5
- Views: 6567
Re: Collision with walls
Set the player.canwalk booleans all to true before you start the for loop, and get rid of them in the if col == false block. My guess is that alone should work, but you could also try that once you determined that there is a collision, you iterate the walls table, then as soon as you've found the b...
- Mon Apr 11, 2016 8:28 am
- Forum: Support and Development
- Topic: Collision with walls
- Replies: 5
- Views: 6567
Re: Collision with walls
Why dont you test the collision using the method on the wiki? https://love2d.org/wiki/BoundingBox.lua function CheckCollision(x1,y1,w1,h1, x2,y2,w2,h2) return x1 < x2+w2 and x2 < x1+w1 and y1 < y2+h2 and y2 < y1+h1 end The collision does work and I am using that function but my issue is that when i...
- Sun Apr 10, 2016 9:24 pm
- Forum: Support and Development
- Topic: Collision with walls
- Replies: 5
- Views: 6567
Collision with walls
Hi im trying to do collision with walls myself but its just hitting the fan. It works kinda, but when i add more walls it just goes to shit. Could anyone offer any help? Im not the best coder and my head is just melting trying to solve this. The problem i think is because of the two "left"...
- Mon Feb 22, 2016 10:08 pm
- Forum: Support and Development
- Topic: Having issue with how bullets are generating when my player rotates
- Replies: 3
- Views: 3443
Re: Having issue with how bullets are generating when my player rotates
I think i phrased my issue wrongly, basically i can get bullets to fire towards the cursor but I dont know how to make it look like its coming out of the gun in the sprite basically
- Mon Feb 22, 2016 9:20 pm
- Forum: Support and Development
- Topic: Having issue with how bullets are generating when my player rotates
- Replies: 3
- Views: 3443
Having issue with how bullets are generating when my player rotates
Hi, im new to game programming but im having a go with a top down shooter. A found an open source sprite online and ive got it to rotate based on where the mouse is but now ive hit a bit of a wall in getting the bullets to rotate their starting position too, im not too sure how to go about it. Thank...
- Mon Feb 01, 2016 9:34 pm
- Forum: Games and Creations
- Topic: First time coding a game, hit a wall
- Replies: 2
- Views: 1857
Re: First time coding a game, hit a wall
Thanks! I managed to fix it using your suggestion with a tweak, instead of (cameraX - love.graphics.getWidth()/2) etc i just did
x = x + cameraX etc
x = x + cameraX etc