Tetris Mini Game

Discussion in 'RGSS3 Scripts (RMVX Ace)' started by GGZiron, Jul 2, 2019.

  1. GGZiron

    GGZiron Veteran Veteran

    Messages:
    58
    Likes Received:
    15
    Location:
    Bulgaria
    First Language:
    Bulgarian
    Primarily Uses:
    RMVXA
    Tetris Mini Game
    • Author: GGZiron

    • Get the script: https://github.com/GGZiron/Tetris-Mini-Game/blob/master/Tetris_Minigame.rb

    • Purpose: Add Tetris as Mini Game in your RPG Maker VX ACE game.

    • Version: 1.1.1
      Version History
      1.0.0 : Initial Release on 02/07/2019.
      1.0.1: Released on 03/07/2019.
      *Fixed a typo I noticed in one of the strings.
      *Removed two unnecessary operations I did in the Audio module.
      1.0.2: Released on 03/07/2019
      *Readded the "unncecessary" operations, and fixed an issue they had
      in initial version.
      1.0.3: Released on 04/07/2019
      *Fixed new possible issues with the Audio module.
      *Fixed an issue where clearing the required number of lines sometimes
      would not increase the hardship level.
      1.0.4: Released on 04/07/2019
      *Now disposing properly a lot of graphical objects, which it wasn't
      previously. Found about it while using Mithran's debugger script.
      1.0.5: Released on 07/07/2019
      *Performance update. In previous version, all stats (level, deleted lines,
      scores, etc) were redrawn whenever one of them changes, causing some lag.
      Now, it redraws only the part that needs to be redrawn, as it should be.
      Did other improvements too.
      1.0.6 Released on 07/07/2019
      *Cleared one visual bug, that came with 1.0.5, and failed to detect it
      initially.
      1.0.7 Released on 09/07/2019
      *Fixed small visual bug.
      *Removed my edit on the Audio module, as I found out the engine
      have methods that do (and do it better) what my edit of the module
      was set to do.
      1.0.8 Released on 10/07/2019
      *Now, when loading older save file, the Tetris script will asume initial
      values for contents that are otherwise extracted from the save file.
      *Now properly initializing Tetris data upon starting new game, which it
      wasn't previously.
      *Improved the action counter, so it counts only successful actions.
      *Other small bug fixes.
      *Some code optimisation.
      1.1.0 Released on 16/07/2019
      *New Option in the "General Options": Make your own tetromino spawning bags!
      *Improved a bit the code about text positioning in "Window Block 1", so changing font or block sizes would not ruin it.
      *Small code optimisations.
      1.1.1 Released on 21/07/2019
      *Now the field is one single sprite, and the building blocks are its
      rectangles. In previous version each building block had its own sprite.
      That doesn't change the Tetris appearance.
      *Did more code optimisations.
    • How easy is to install:

      Vary.
      If you are happy with my Tetris as it is, then is plug and play. Easy.
      But if you are not, then there are lot of settings, including redesign of Tetris Scene. Doing something with them might not be as easy, but may make your version of the tetris little bit more unique, or better fit to your RPG game.

    • Compatibility:
      Placed this script at the bottom of my most script - crowded project, and had no problems. Most of the things I do are in my module, although I had to overwrite (and alias first) several methods from the engine's scripts.
      Trying to make very unique names in the new methods and properties I add into the engine's scripts.
      My Tetris Mini game adds additional bits to the save data: last game scores, best scores, total actions, total deleted lines and the internal Tetris timer.

    • How to use:
      By default, the option to play Tetris will appear on the main menu. With the settings, you can hide it or disable it. You can hide or disable/enable any time of the game with script call. Also, you can run the Tetris scene with this script call:
      Code:
      scene = GGZiron_Tetris::Scene_Tetris
      SceneManager.call(scene)
      

    • Features:
      Nine levels. Each with own music and speed.
      Battle musics in the engine conveniently are 9 too, so I use them.
      But can have global music for all or as many levels you want instead.

      Own Vocab settings, where you can change all the text strings that come with my tetris.

      Game play wise, it rewards clearing lines. More lines at once, bigger the reward. The hardship level is used as multiplier of the scores reward. It have wall kick (trying to rotate tetromino too close to obstacle, and it will try to move one step away, then attempt rotate again). For now, didn't design fancy stuffs like ghost tetromino (seeing where it goes to land) or spin rewards.

      In game timer, that measure the total time the player spent in this mini game within one save.
      Works in frames. Doesn't count paused time, Tetris "Game Over" time and time outside Tetris mini game.

      Various stats display, that you can see in the screen shot. There are script calls to obtain some of those
      stats out of the Tetris Minigame, so you can use it to reward or punish the player.

      Tetrominoes (The Tetris figure) have different color each, that use RGB code set in the settings.

      Controls configuration in the settings.

      With version 1.1.0, you can set your own spawning paterns.

    • Screen Shot: (taken on full screen)
      Having no fitting background picture, but you can change it the settings.
      Window position and other properties are also subject to change in settings.
      [​IMG]
    • Author notes:
      The idea to make tetris script came from Neo_Kum0rius_6000's script request thread, although I started doing my tetris much later. If you see any bug, or have suggestion, you can post on this script thread on RPG Maker forum, or pm me. My script surely have flaws. Would gladly improve it, when I have time, and if there is interest on it.

    • Terms:
      Terms of use: Free for commercial and non commercial projects.
      Free to edit, but keep my part of the header, and don't claim the script is yours.
      You have to credit me as GGZiron.
      Update: Added GNU General Public License v3.0, which basically permits the same things.
      You can review it here: https://github.com/GGZiron/Tetris-Mini-Game/blob/master/LICENSE
      And here: https://www.gnu.org/licenses/gpl-3.0.html
     
    Last edited: Jul 21, 2019 at 5:17 PM
    #1

Share This Page