java - Finding x and y offset according to new screen resolution -


i have android game need draw object based on coordinates chosen player. sent opponent. need draw object in same position on new screen. have right now

float x = originalx; float y = originaly;  x *= mywidth / originalwidth; y *= myheight / originalheight;  drawrect(x, y, x+width, y+width); 

it doesn't seem work. guesses?


Comments