oosidat / NASAHack2014-asteroids

Rocks! Lasers! Profit!
http://rockslasersprofit.com
Other
1 stars 1 forks source link

Radar Camera becomes misaligned with most resolutions #3

Open ssshake opened 10 years ago

ssshake commented 10 years ago

Most often the mini map is misaligned with many resolutions. I think this is because it reads x,y co-ordinates from the bottom left of the screen. We need to do some calculation to place the radar camera based on screen dimensions.

The camera isnt placed in 3d space, there's options in the editor to place it in a 2d x,y space relative to the main camera's view.

oosidat commented 10 years ago

The issue is not limited to the mini-map. Based on our demo, the issue may also extend to other points of interaction. See #2

ssshake commented 10 years ago

I think the issues are separate.

The position on the radar is for sure wrong with certain resolutions but the other things you click on aren't. I'm fairly positive that the issue you experienced was because of changing the screen res after the application was already running. This messes up only the mouse co-ords. Not on screen visuals.

I think unity samples the screen dimensions once at start up, so if the dimensions change mid game without a refresh of that data, it will be off.

oosidat commented 10 years ago

Any luck with this one so far? I tried tinkering around last night, didn't get anywhere with it.

ssshake commented 10 years ago

Hadn't started. I think whats happening is different than I first though. I think because th GUI is objects in space not guitextures, their size/position is different for different resolutions. Not ideal. I did real object in space over guitexture to play better with oculus rift (which we descoped) The entire GUI should be rewritten as guitextures and guitext. However in the interest of time I think the easiest solution is to hard set the game to one resolution and one aspect ratio in the player settings.  I can probably experiment tonight. From: Osama SidatSent: Wednesday, April 16, 2014 2:45 PMTo: oosidat/NASAHack2014-asteroidsReply To: oosidat/NASAHack2014-asteroidsCc: ssshakeSubject: Re: [NASAHack2014-asteroids] Radar Camera becomes misaligned with most resolutions (#3)Any luck with this one so far? I tried tinkering around last night, didn't get anywhere with it.

—Reply to this email directly or view it on GitHub.

oosidat commented 10 years ago

Sounds fair - at this point, I don't mind if our fixes are quick and get rid of the user-facing problem(s).

ssshake commented 10 years ago

I've configured the radar cam to look right on 960x600 which is the webplayers default. I set the windows player settings to the same with no prompt/choice for the user to choose. Need to make sure we do this with other platforms.

I'm descoping this issue from the current milestone but keeping it open so we can fix it properly later.

ssshake commented 10 years ago

alternative option is to use a render texture