RMRK is retiring.
Registration is disabled. The site will remain online, but eventually become a read-only archive. More information.

RMRK.net has nothing to do with Blockchains, Cryptocurrency or NFTs. We have been around since the early 2000s, but there is a new group using the RMRK name that deals with those things. We have nothing to do with them.
NFTs are a scam, and if somebody is trying to persuade you to buy or invest in crypto/blockchain/NFT content, please turn them down and save your money. See this video for more information.
[REQUEST][XP] Overworld Sprites Help

0 Members and 1 Guest are viewing this topic.

**
Rep:
Level 82
Hey guys,
      I'm using a "Tiny Overworld Sprites" script (i think done by ccoa, I could be wrong though). I was wondering if there was any way to possibly turn off the "zoom" feature when, say I enter a vehicle and a switch is flipped. Any help would be appreciated!

Here's the script:
Code: [Select]
# change this to any number less than one to change the size of the world map
# sprites
ZOOM = 0.6
WORLD_IND = 'World Map'

class Game_Map
  attr_reader :name
  attr_reader :isworldmap
 
  alias ccoa_setup setup
  #--------------------------------------------------------------------------
  # * Setup
  #     map_id : map ID
  #--------------------------------------------------------------------------
  def setup(map_id)
    ccoa_setup(map_id)
    @name = load_data("Data/MapInfos.rxdata")[@map_id].name
    if @name.include?(WORLD_IND)
      @isworldmap = true
      @name.sub!(WORLD_IND, '')
    else
      @isworldmap = false
    end
  end
end

class Sprite_Character < RPG::Sprite
  alias ccoa_update update
  #--------------------------------------------------------------------------
  # * Frame Update
  #--------------------------------------------------------------------------
  def update
    ccoa_update
    if @character.is_a?(Game_Player) and $game_map.isworldmap
      self.zoom_x = ZOOM
      self.zoom_y = ZOOM
    else
      self.zoom_x = 1.0
      self.zoom_y = 1.0
    end
  end
end