Jump to content


Photo

Frame Around Game Window


  • Please log in to reply
5 replies to this topic

#1 megaleon

megaleon

    GMC Member

  • New Member
  • 91 posts

Posted 26 May 2010 - 02:59 PM

Hi guys
Stright to the question: it is possible to have a frame around the game window?
Here is what I have now:
Posted Image

I wanted to simulate a fake gameboy-like handheld.
Currently, the room is 160*160, the frame is a foreground image, and all the action happens in the 96*96 visible square. That means I have to shift all the actions 16 pixels right and down compared to the origin 0,0.
I was asking: is there a wat to have a 96*96 room and then outputting the game with the frame?

Thanks guys.

Edited by megaleon, 26 May 2010 - 05:24 PM.

  • 0

#2 RocketLauncher3G

RocketLauncher3G

    Int. Game Programmer

  • GMC Member
  • 627 posts

Posted 26 May 2010 - 03:01 PM

now, but you can however play with the viewport. Viewport is the place of the view compared to the origin 0,0 :)
  • 0

#3 megaleon

megaleon

    GMC Member

  • New Member
  • 91 posts

Posted 26 May 2010 - 05:28 PM

now, but you can however play with the viewport. Viewport is the place of the view compared to the origin 0,0 :)

You mean using views?
I tried playing with them a little, but I'm not able to accomplish what I would like to:
To program considering the top left of the screen at 0,0 instead of 16,16, and then shifting everything 16 pixel down-right.
  • 0

#4 GloryAndBen

GloryAndBen

    Game Programmer

  • GMC Member
  • 943 posts

Posted 26 May 2010 - 05:46 PM

Just use (16,16) for the "Port on screen" box under view0.
  • 0

#5 megaleon

megaleon

    GMC Member

  • New Member
  • 91 posts

Posted 26 May 2010 - 08:48 PM

Just use (16,16) for the "Port on screen" box under view0.

But doing so, the foreground frame is shifted as well.
  • 0

#6 GloryAndBen

GloryAndBen

    Game Programmer

  • GMC Member
  • 943 posts

Posted 26 May 2010 - 09:48 PM

Then draw the foreground image off-screen, and then set the view1 "View in room" coordinates to the coordinates of the forground image.
  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users