Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

How to create a 2D game

Wictorian
 Share

I was using pygame but I hate its coordinate system. Do you suggest anything more comfortable?

 

Link to comment
Share on other sites

Link to post
Share on other sites

2 minutes ago, Wictorian said:

I was using pygame but I hate its coordinate system. Do you suggest anything more comfortable?

 

What is your target platform?

A PC Enthusiast since 2011
AMD Ryzen 5 2600@4.1GHz | GIGABYTE GTX 1660 GAMING OC @ Core 2085MHz Memory 5000MHz
Cinebench R15: 1349cb | Unigine Superposition 1080p Extreme: 3566
Link to comment
Share on other sites

Link to post
Share on other sites

3 minutes ago, Vishera said:

What is your target platform?

Doesn’t matter much. Pc is okay. 

Link to comment
Share on other sites

Link to post
Share on other sites

18 hours ago, Wictorian said:

I hate its coordinate system

Write a function and use that to transform coordinates from one system to the other.

ಠ_ಠ

Link to comment
Share on other sites

Link to post
Share on other sites

3 hours ago, shadow_ray said:

Write a function and use that to transform coordinates from one system to the other.

To what? Engines like Unity handle it like a god already.

Link to comment
Share on other sites

Link to post
Share on other sites

1 hour ago, Wictorian said:

To what?

Thats upto you. Pygame draws from top left to bottom right.

What dont you like about that?

How do you want it to draw?

 

You can write your own simple helper function to translate your games coordinate system to pygames coordinates.

Example, to treat 0,0 as the center of the screen do something like this suggestion

https://stackoverflow.com/questions/61514113/how-do-i-change-the-pygame-coordinate-system-so-that-the-center-of-the-window-is

 

Link to comment
Share on other sites

Link to post
Share on other sites

10 hours ago, C2dan88 said:

Thats upto you. Pygame draws from top left to bottom right.

What dont you like about that?

How do you want it to draw?

 

You can write your own simple helper function to translate your games coordinate system to pygames coordinates.

Example, to treat 0,0 as the center of the screen do something like this suggestion

https://stackoverflow.com/questions/61514113/how-do-i-change-the-pygame-coordinate-system-so-that-the-center-of-the-window-is

 

I just don’t want to deal with coordinates at all. 

Link to comment
Share on other sites

Link to post
Share on other sites

14 hours ago, Wictorian said:

I just don’t want to deal with coordinates at all. 

Then you'll have to find an existing engine that comes with some form of visual editor, that hides its coordinate system and associated transformations between world space and screen space from you. Even then, I'm not sure you'll be able to avoid dealing with it entirely.

Remember to either quote or @mention others, so they are notified of your reply

Link to comment
Share on other sites

Link to post
Share on other sites

22 hours ago, Eigenvektor said:

Then you'll have to find an existing engine that comes with some form of visual editor, that hides its coordinate system and associated transformations between world space and screen space from you. Even then, I'm not sure you'll be able to avoid dealing with it entirely.

what I mean is I want to minimize the amount of inconvenience they cause. I think Unity is good  at that?

Link to comment
Share on other sites

Link to post
Share on other sites

Do you have an idea on how you would like to place your entities on screen and move they if you don't want to give them coordinate or vector displacement ?

 

Right now what you are saying doesn't make much sense so maybe you need to explain a little bit more what's your target here.

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share


×