Author Topic: [Game] How to Center HUD Shapes  (Read 203 times)

0 Members and 1 Guest are viewing this topic.

Lunar

  • Elite Member
  • *****
  • Posts: 878
  • The God of the Galaxy
  • Awards 1 year on site+100 posts
    • View Profile
    • Awards
  • Xbox: Qvzw
  • PSN: Widumn_Boise
[Game] How to Center HUD Shapes
« on: November 27, 2016, 06:17:27 PM »
If you need to center a HUD Shape or a HUD Bar, just use these simple steps.

1. Take the width of your HUD (i.e. 400)
2. Do 1280 - The Width (i.e. 1280 - 400 = 880)
3. Half that number (i.e. 880 / 2 = 440)
4.  That last number is your X Position!

Example:

1. 400 (Width of HUD)
2. 1280 - 400 = 880
3. 880 / 2 = 440
4. X Position: 440


Repeat the same process for the Y position too, except substitute 1280 with 720, and of course replace the width with the height.

Example:

1. 160 (Height of HUD)
2. 720 - 160 = 560
3. 560 / 2 = 280
4. Y Position: 280

RemoteBeef092

  • Fresh Meat
  • *
  • Posts: 4
  • Rubber
    • View Profile
    • Awards
  • Xbox: RemoteBeef092
  • Steam: RemoteBeef092
Re: How to Center HUD Shapes
« Reply #1 on: January 23, 2017, 10:39:08 AM »
Very helpful, thank you.
Hi, I am the master of potatoes.