Report as inappropriate.
This is a small demo of making a full-screen scenario. It works best when you export your scenario to a jar. Just make your world a subclass of ScaleWorld and your actors, a subclass of ScaleActor. My goal with this was to make it where you could design your scenario for 600by400 for example, but have it change the numbers for you when it scales the screen. This (hopefully) means you can copy most of your code into the scenario, and it will turn out just the same. I have modified move(), setLocation(), addObject(), getX(), getY(), and and it also directly modifies the size of actor's images to make up for the scaling. Finally, if you want to use a method like getImage().getColorAt(130,150), you would use the scaleX() and scaleY() methods in the world class: i.e. getImage().getColorAt(((ScaleWorld)getWorld()).scaleX(130),((ScaleWorld)getWorld().)scaleY(150));
2123 views / 13 in the last 7 days
1 vote | 0 in the last 7 days
This scenario is a member of: Tools
Want to leave a comment? You must first log in.