Eliaquim

Hakuen Studio
Veteran
Joined
May 22, 2018
Messages
1,883
Reaction score
1,360
First Language
Portuguese - Br
Primarily Uses
RMMZ
Qplus_noTilemap

Author Quxios *No longer supported*

Introduction

Its an edited version from the plugin Qplus.js, made by Quxios;

Features
Removes all functionality from the original Qplus.js plugin and leaves only the feature of replacing the tilemap with a lighter sprite.
It will "remove" all your tilesets from be showing on the map. But the passages in the database will still work.


Screenshots
QymHMQT.png


How to Use
Just put the note tag on map notes:
<noTilemap>

JavaScript:
//=============================================================================
// QPlus_noTilemap.js
//=============================================================================
 
/*:
 * @plugindesc QPlus noTilemap
 * @author Quxios
 * @site https://quxios.github.io/
 *
 * @help
 * I edited the original plugin QPlus from Quxios to only have the feature
 * "No Tile Map" that helps when you go all parallax in your game.
 * Despite removing the tilemap the passages marked in the database continue
 * to function normally.
 * Please, follow the terms of use from Quoxios. No need to credit me.
 *_____________________________________________________________________________
 *
 * Eu editei o plugin QPlus original de Quxios para ter apenas o recurso
 * "No Tile Map", que pode ajudar na performance de um jogo que usa somente
 * parallaxes.
 * Apesar de remover o tilemap, as passagens marcadas no banco de dados
 * continuam funcionando normalmente.
 * Por favor, siga os termos de uso de Quoxios. Não precisa me dar créditos.
 *
 * ----------------------------------------------------------------------------
 * **No tilemap**
 * ----------------------------------------------------------------------------
 * You can disable the tile map by adding this note to a map
 * ~~~
 * <noTilemap>
 * ~~~
 * This will replace the tilemap with a simple light weight sprite container.
 * Using this may increase performance. So if you have a map that doesn't use
 * any tiles and is all parallax, then you should considering using this.
 *
 * *Note, there's a chance this may break some plugins if they call functions in
 * the original tilemap class.*
 *
 * Terms of use:
 *
 *  https://github.com/quxios/QMV-Master-Demo/blob/master/readme.md
 *
 * Like my plugins? Support me on *******!
 *
 *  https://www.*******.com/quxios
 */

//-----------------------------------------------------------------------------
// SimpleTilemap
//656
function SimpleTilemap() {
  this.initialize.apply(this, arguments);
}

(function() {
//984
Game_Map.prototype.noTilemap = function() {
    return !!$dataMap.meta.noTilemap;
  };
 
//1195
//-----------------------------------------------------------------------------
// Sprite_Character

  var Alias_Sprite_Character_updatePosition = Sprite_Character.prototype.updatePosition;
  Sprite_Character.prototype.updatePosition = function() {
    var prevY = this.y;
    var prevZ = this.z;
    Alias_Sprite_Character_updatePosition.call(this);
    if (this.y !== prevY || this.z !== prevZ) {
      if ($gameMap.noTilemap && this.parent && this.parent.requestSort) {
        this.parent.requestSort();
      }
    }
  };

//-----------------------------------------------------------------------------
// Spriteset_Map
 
  var Alias_Spriteset_Map_createTilemap = Spriteset_Map.prototype.createTilemap;
  Spriteset_Map.prototype.createTilemap = function() {
    if ($gameMap.noTilemap()) {
      this._tilemap = new SimpleTilemap();
      this._baseSprite.addChild(this._tilemap);
    } else {
      Alias_Spriteset_Map_createTilemap.call(this);
    }
  };

  var Alias_Spriteset_Map_loadTileset = Spriteset_Map.prototype.loadTileset;
  Spriteset_Map.prototype.loadTileset = function() {
    if (!$gameMap.noTilemap()) {
      Alias_Spriteset_Map_loadTileset.call(this);
    }
  };

  var Alias_Spriteset_Map_updateTilemap = Spriteset_Map.prototype.updateTilemap;
  Spriteset_Map.prototype.updateTilemap = function() {
    if (!$gameMap.noTilemap()) {
      Alias_Spriteset_Map_updateTilemap.call(this);
    }
  };

  //-----------------------------------------------------------------------------
  // SimpleTilemap

  SimpleTilemap.prototype = Object.create(Sprite.prototype);
  SimpleTilemap.prototype.constructor = SimpleTilemap;

  SimpleTilemap.prototype.initialize = function() {
    Sprite.prototype.initialize.call(this);
    this._requestSort = false;
  };

  SimpleTilemap.prototype.requestSort = function() {
    this._requestSort = true;
  };

  SimpleTilemap.prototype.update = function() {
    Sprite.prototype.update.call(this);
    if (this._requestSort) {
      this._sortChildren();
    }
  };

  SimpleTilemap.prototype._sortChildren = function() {
    this.children.sort(this._compareChildOrder.bind(this));
  };

  SimpleTilemap.prototype._compareChildOrder = function(a, b) {
    if (a.z !== b.z) {
      return a.z - b.z;
    } else if (a.y !== b.y) {
      return a.y - b.y;
    } else {
      return (a.spriteId - b.spriteId) || 0;
    }
  };
 
  })()


Credit and Thanks

- Don't credit me. Only the author.
- Below are the terms of the author.
Terms
Free to use for commercial and non-commercial projects. More information at https://github.com/quxios/QMV-Master-Demo#terms-of-use-for-non-commercial-and-commercial

Notes
- It worked flawlessly with GalvLayers.
 
Last edited:

Eliaquim

Hakuen Studio
Veteran
Joined
May 22, 2018
Messages
1,883
Reaction score
1,360
First Language
Portuguese - Br
Primarily Uses
RMMZ
Attached the plugin to the first post. I will no longer host it.
 

Latest Threads

Latest Profile Posts

besides itch and occasionally here where are people doing game jams at y'all? (plz do not cross reference this with my previous status lol)
Go out all day!
★No work★
Just want to sleep when I get home Zzzzz
just went through 50 issues of Fables, only to left kind of disappointed by it, I guess I have to wait for season 2 of TWAU instead.
Untitled Project.gif

Feel free to subscribe, cuz im gonna release it first there.
https://crashykk.itch.io/crashykk-retro-tileset
and_remember_tomorrow_beside_myself.jpg

The worst part about making custom stuff is, I can't really ask any of you why a second copy of the character randomly appears only when going SW, S, or SE and changing directions. Been bugging me for the last two days. On the plus side, look at the new random map pieces I made while thinking about it.:LZSexcite:

Forum statistics

Threads
110,434
Messages
1,053,263
Members
143,499
Latest member
flixhqtv
Top