JakeJayB / Bug-Jump-Group-Application

Bug Jump is a 2D platformer game which I was the lead programmer for, leading a group of 4 undergraduate students
0 stars 0 forks source link

Implement a Level Creator #2

Open JakeJayB opened 8 months ago

JakeJayB commented 8 months ago

The current version of the game has a file reader where it reads game content in text format and translates it into a playable scene. There are currently 8 level files which the file reader reads from. The problem with this system is that it's inconvenient to create a level in text format without seeing how the scene updates. The only way to see what the level looks like is by running the program and have the file reader load the level. To solve this problem, I propose to create a level creator.

The level creator will be a separate scene from the main game and tutorial scenes. its main purpose will be to allow the user to create a level while, at the same time, showing the user how the level looks as they change the scene. The user will be able to instantiate all objects from the game to create the level of theirs dreams (This will be done through number keys 0-9). They will also have the ability to resize(selecting an object and using GUI to resize) and delete(delete key) any gameobject from the scene. Once the user is done creating their level, the level creator will create a level file based on where the gameobjects are located in the scene. the level file will be stored with the other base levels for the level selector class to display

Since the level creator will be its own separate scene, it must have its own class with its own data members and GUI. Here is how the level creator will be implemented

  1. GUI: the only GUI that will be displayed are the GImages that represent game objects, and the GParagraphs and GButtons for resizing GImages.
  2. Resizing GImages: the user must click (not drag) a object's GImages and use the GButtons at the top left of the screen to resize gameobjects. There will be Gparagraphs that show what each button does (ex: "Obj. width", "Obj. Height", etc). I will use mouseClicked() for this
  3. moving Gimages: the user must press and drag object's Gimages to move them across the screen. will use mousePressed() and mouseDragged() for this
  4. Deleting GImages: The user must click not drag) a object's GImages and press the "backspace" key to delete an object. Will you keyPressed() and mouseClicked() for this
  5. Spawning gameobjects: objects will be keybinned to the keyboard's number key's 0-9. clicking on any of those keys will spawn in an object. will use keyPressed() for this
  6. move entire screen: when the mouse gets to the left/right edge of the screen, the screen will move to that direction and gameobjects will move the opposite direction. I will use actionPerform() for this.
onzfonz commented 8 months ago

This looks good! Might be ambitious so start off with crating a file that can be used to begin with