Search found 191 matches

by nice
Wed Mar 08, 2017 6:03 pm
Forum: Support and Development
Topic: Help: Advice on how to make my ball in Pong project "bounce"
Replies: 7
Views: 4997

Re: Help: Advice on how to make my ball in Pong project "bounce"

That's the field of collision and response. You need to detect collision and issue appropriate response action. You could use existing physics libraries for that, or do all the math yourself. Yeah I figured that collision detection will be the problem and Jasoco recommended that I look up Bump . I ...
by nice
Wed Mar 08, 2017 6:00 pm
Forum: Support and Development
Topic: Help: Advice on how to make my ball in Pong project "bounce"
Replies: 7
Views: 4997

Re: Help: Advice on how to make my ball in Pong project "bounce"

Look into Bump. It'll make it easier. Otherwise you'll have to do the math yourself. A bunch of if checks on the position of the ball and the paddle. I'll take a look at Bump but right now I think my problem is to know when my ball and paddle collide with eachother. I'm thinking something like &quo...
by nice
Tue Mar 07, 2017 10:47 pm
Forum: Support and Development
Topic: Help: Advice on how to make my ball in Pong project "bounce"
Replies: 7
Views: 4997

Help: Advice on how to make my ball in Pong project "bounce"

Hello everyone! I'm currently working on trying to replicate Pong to learn how Löve2D/Lua works and I think I've come to the point where I want the ball in my game to bounce around. As you can see in the gif that I've attached that the Ball just moves to the left and doesn't bounce back against the ...
by nice
Mon Mar 06, 2017 7:30 pm
Forum: General
Topic: Shockwave effect
Replies: 11
Views: 9198

Re: Shockwave effect

This is super cool!
It felt like I was pulling a water-blob around the screen!
by nice
Fri Mar 03, 2017 3:14 pm
Forum: General
Topic: [Solved] How to make an object move in 8 directions
Replies: 7
Views: 7101

Re: [HELP] How to make an object move in 8 directions

function love.update(dt) -- Super simple movement if love.keyboard.isDown("w") then moveY = moveY - 100 * dt elseif love.keyboard.isDown("s") then moveY = moveY + 100 * dt end if love.keyboard.isDown("a") then moveX = moveX - 100 * dt elseif love.keyboard.isDown("...
by nice
Fri Mar 03, 2017 11:11 am
Forum: General
Topic: [Solved] How to make an object move in 8 directions
Replies: 7
Views: 7101

[Solved] How to make an object move in 8 directions

Hello! So a week or so I came back to Löve2D and I started to play around with it and at the moment I've implemented a very simple movement code that moves a rectangle in 4 different directions: function love.load() --Movement -- movePlayer = true moveX = 100 moveY = 100 cyan = love.graphics.setColo...
by nice
Tue Feb 28, 2017 5:35 pm
Forum: General
Topic: Is there a way to group lines of code in Löve?
Replies: 18
Views: 12431

Re: Is there a way to group lines of code in Löve?

Well I guess that I perhaps I should've provided a clearer answer for next time, like a link that better explains my intentions.
by nice
Mon Feb 27, 2017 8:06 pm
Forum: General
Topic: Is there a way to group lines of code in Löve?
Replies: 18
Views: 12431

Re: Is there a way to group lines of code in Löve?

zorg wrote: Mon Feb 27, 2017 8:02 pm Or, instead of commenting out stuff, use versioning and revert if something doesn't work as you expected it to :3
(Might be overkill though, but it doesn't hurt learning git or something)
I have been using Sourcetree and currently using TortoiseHG but all in due time
by nice
Mon Feb 27, 2017 8:04 pm
Forum: General
Topic: Is there a way to group lines of code in Löve?
Replies: 18
Views: 12431

Re: Is there a way to group lines of code in Löve?

airstruck wrote: Mon Feb 27, 2017 7:55 pm
nice wrote: Mon Feb 27, 2017 7:51 pm If you want pretty, delete all those comments and call it a day. I doubt you'll miss them much. ;)
You're so right :nyu: but since my memory is sometimes like an goldfish, I think it's for the better it's there so it reminds me
by nice
Mon Feb 27, 2017 7:51 pm
Forum: General
Topic: Is there a way to group lines of code in Löve?
Replies: 18
Views: 12431

Re: Is there a way to group lines of code in Löve?

Hmm, so really you want to fold up a bunch of comments? You could wrap the whole thing in a multiline comment, like this: --[==[ ...other comments here... --]==] The thing with the equals signs is a special syntax for block comments that happen to contain ]] (or ]=], or ]==], etc.). Just make sure ...