Search found 243 matches

by Tjakka5
Wed Jul 09, 2014 5:14 pm
Forum: Support and Development
Topic: [SOLVED] Calling a variable function.
Replies: 9
Views: 6325

[SOLVED] Calling a variable function.

Not really clear title, so time for some backstory. I've been making some "test programs" to try out things that will be neccesary for a big game I want to make at some point. The game will be a sandbox game, with lots of building blocks and items, thus I want the functions updating and dr...
by Tjakka5
Sun May 11, 2014 2:40 pm
Forum: Support and Development
Topic: Would a constantly updating 1024x grid lag?
Replies: 7
Views: 1670

Re: Would a constantly updating 1024x grid lag?

Common task would be the following: "Change sprite" "Delete parts of inventory" "Spawn something in inventory" "Decrease/increase a state by x" There could also be some more complex calculations, but these would be the majority. Also, I'd personally not update...
by Tjakka5
Sun May 11, 2014 1:51 pm
Forum: Support and Development
Topic: Would a constantly updating 1024x grid lag?
Replies: 7
Views: 1670

Would a constantly updating 1024x grid lag?

Unclear topic title is unclear. I'm planning on making a somewhat technical game. You spawn in a world which is saved as a 1024*1024 grid. On every spot on that grid there can be a objects; a furnace, a chest, air, or whatever. Now, most of these objects will do something. Always do something, or on...
by Tjakka5
Sun Feb 23, 2014 6:07 pm
Forum: Support and Development
Topic: Collision with multiple entities?
Replies: 6
Views: 2663

Re: Collision with multiple entities?

EDIT: Sorry misread that.

Its working now; thanks :)

EDIT2: Actually, its far from working.
The one entity seems so collide with the other, but only one of them stops moving the other one just continues moving.

EDIT3: And fixed, but the collision is really derpy; I shall work on that then.
by Tjakka5
Sun Feb 23, 2014 6:00 pm
Forum: Support and Development
Topic: Collision with multiple entities?
Replies: 6
Views: 2663

Re: Collision with multiple entities?

function returnColliding(a, b) return a.xPos < b.xPos + 64 and b.xPos < a.xPos + 64 and a.yPos < b.yPos + 64 and b.yPos < a.yPos + 64 end function isColliding() for i = 1, #enemy-1 do for j = i+1, #enemy do local enemyA = enemy[i] local enemyB = enemy[j] if returnColliding(enemyA, enemyB) then i.xV...
by Tjakka5
Sun Feb 23, 2014 5:12 pm
Forum: Support and Development
Topic: Collision with multiple entities?
Replies: 6
Views: 2663

Re: Collision with multiple entities?

I had a look at that function.

Again, the problem is that I don't know how I should deal if there's a collision happening.
Another thing is that the entities need to collide with the others too.
by Tjakka5
Sun Feb 23, 2014 4:41 pm
Forum: Support and Development
Topic: Collision with multiple entities?
Replies: 6
Views: 2663

Collision with multiple entities?

Hello everyone, I'm still getting the hang of Love2d, and I just spend some hours making basic movement and a AI that follows you. However, I'm currently stuck trying to make the entities collide with each other and the player. I have no idea how to do this, and I dont want to use the physics engine...
by Tjakka5
Sat Jan 04, 2014 7:25 pm
Forum: Support and Development
Topic: I dont think this is the proper way to make entities.
Replies: 5
Views: 1743

Re: I dont think this is the proper way to make entities.

But each bullet has each own data, as mentioned above, position and velocity.
How would you recommend it doing it that way then?
by Tjakka5
Sat Jan 04, 2014 7:18 pm
Forum: Support and Development
Topic: I dont think this is the proper way to make entities.
Replies: 5
Views: 1743

I dont think this is the proper way to make entities.

Hello, I've just been having some fun with movement, and decided I could turn it into a game where red blocks fall from the ceiling and you have to dodge them. These boxes should all have a position and a speed, but I dont think this is the right way to do it. local player = { xPos = 7, yPos = 7, xV...
by Tjakka5
Fri Dec 27, 2013 8:11 am
Forum: Support and Development
Topic: Ideas for "new" physics?
Replies: 6
Views: 2471

Re: Ideas for "new" physics?

Thanks for all the ideas guys! I especially like the suggestion where water is less dense as air.