How do you implement circular movement in language c?

Asked 2 years ago, Updated 2 years ago, 48 views

I'm trying to make a game like Gallagher in C language, and the rest of the elements are all implemented, but they're blocked at the stage of implementing the movement of the enemy. It'd be nice if it was a simple random move, but it's too hard to guessAs I see it, I want to implement the movement of the enemy plane in a circle. When I searched the Internet, they told me to use a trigonometric function or an equation of a circle, but I didn't know how to implement it even though I saw it with a score of 30. I wonder how to implement it in detail.

c function

2022-09-21 21:03

1 Answers

You can find it by just looking for Wiki. And if you google it, it'll come out like heaven and earth.

https://ko.wikipedia.org/wiki/%EC%9B%90_(%EA%B8%B0%ED%95%98%ED%95%99)

For reference, use the parameter equation shown in the wiki.

Programming usually does not use the general form of the equation of XX. Because you can't express direct relational expressions for different variables in programming language.

Turning theory into code is one of the virtues of engineers. Fighting.


2022-09-21 21:03

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.