Learn more. My first time trying to make a simple tile-based java game Ask Question. Asked 8 years, 8 months ago. Active 8 years, 8 months ago. Viewed 3k times. I'll post my code: frame. Color; import java. Dimension; import java. Graphics; import java.
Image; import javax. Image; import java. BufferedReader; import java. File; import java. FileReader; import java. IOException; import javax. ImageIO; import javax. Improve this question. NEVER use this. Add a comment. Active Oldest Votes. The way I do is hardcoding every Tile with it's number.
Improve this answer. Thanks Sri Harsha Chilakapati, I tried that it worked. But is there a more dynamic way of doing it? Like without hard-coding all the tiles. More dynamic way? You can use Reflection but I'm not sure of it. Sign up or log in Sign up using Google.
Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. Podcast Helping communities build their own LTE networks. Move entities with acceleration respecting friction and weight. Convey three-dimensionality with distinct render layers. WAV ,. OGG , and. MP3 audio files.
Import maps and resources. Manipulate Lighting and Entities, then admire the results directly in-engine. TMX format. Subscribe to entity events and send messages amongst entities. Control entity animation, movement, and behaviour with EntityControllers.
UI Framework Manage multiple game and menu screens. Improve the user experience with highly customizable GUI components.
0コメント