S
S
Satangelus2018-05-12 23:25:28
Android
Satangelus, 2018-05-12 23:25:28

[Android gamedev] How to avoid large delays when handling collisions (collisions)?

There is an object that the player controls - 1 piece. Obstacles - about 60-70 pieces. Cookies - about 40-50 pieces per level. And evil objects (from which you need to escape) - about 10 pieces.
Problems began already at the stage of processing the movement of the main character. First check for collisions when moving horizontally, and then again the same check for moving vertically. And then another check for eaten cookies. The result is visible delays in the movement of the GG. I'm afraid that everything will become a stake when I add the movement of evil objects.
The question is, how can you solve the problem with processing a large number of collisions?
Z.Y.Zh. Well, or at least throw a link from which you can get sensible information.
Thank you all in advance
.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
G
GavriKos, 2018-05-13
@GavriKos

The question requires clarification:
1) What kind of engine and PL?
2) What is the algorithm for handling collisions?
3) What does the profiler show?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question