Postaci nad obrazkami
Aktualny czas: 28-04-26, 23:33 Witaj! Przejdź do zakładki Logowanie lub Rejestracja


Wątek zamknięty 
[VXAce] Postaci nad obrazkami
Ayene Offline
*


Liczba postów: 758
Dołączył: 09-04-13

Pomógł: 112



Post: #3
RE: Postaci nad obrazkami

Przełożyłam skrypt Woratany. Powinien działać, choć nie testowałam z modern algebrą.
#===============================================================
# ● [VXA] ◦ Pictures under Characters ◦ □
# * Show pictures under characters on map but above map tiles *
#--------------------------------------------------------------
# ◦ by Woratana [woratana@hotmail.com]
# ◦ Thaiware RPG Maker Community
# ◦ Released on: 22/02/2009
# ◦ Version: 1.0
#--------------------------------------------------------------
# ◦ Update:
#--------------------------------------------------------------
# □ Version 1.0 (22/02/2009)
# - Unlimited numbers of picture under characters
#
#--------------------------------------------------------------
# ◦ Compatibility:
#--------------------------------------------------------------
# □ This script will rewrite 0 method(s):
#
#
# □ This script will alias 2 method(s):
#     Spriteset_Map.create_pictures
#     Sprite_Picture.update
#
# □ This script should work with most scripts
#
#--------------------------------------------------------------
# ◦ Installation:
#--------------------------------------------------------------
# 1) This script should be placed JUST AFTER ▼ Materials.
#
# □ Like this:
# ▼ Materials
# *Pictures under Characters
# ...
# ...
# ▼ Main Process
# Main
#
# 2) Setup this script in Setup Part below.
#
#--------------------------------------------------------------
# ◦ How to use:
#--------------------------------------------------------------
# □ Place this script and setup in the setup part.
#
#=================================================================

class Spriteset_Map

  #=================================================================
  # ++ Setup Part
  #-----------------------------------------------------------------
  FIRST_PICBELOW_ID = 15 # First ID of picture that will show below characters
  LAST_PICBELOW_ID = 20 # Last ID of picture that will show below characters

  # For example, if you set FIRST to 10 and LAST to 15, picture ID 10-15
  # will show below characters on map.
  #=================================================================
  #--------------------------------------------------------------------------
  # * Create Picture Sprite
  #--------------------------------------------------------------------------
  def update_pictures
    $game_map.screen.pictures.each do |pic|      
      if (FIRST_PICBELOW_ID..LAST_PICBELOW_ID).include?(pic.number)
        @picture_sprites[pic.number] ||= Sprite_Picture.new(@viewport1, pic)
      else
        @picture_sprites[pic.number] ||= Sprite_Picture.new(@viewport2, pic)
      end  
      @picture_sprites[pic.number].update
    end
  end
end

class Sprite_Picture < Sprite
  alias wora_picbelow_sprpic_upd update
  #--------------------------------------------------------------------------
  # * Frame Update
  #--------------------------------------------------------------------------
  def update(*args)
    wora_picbelow_sprpic_upd(*args)
    self.z = $game_player.screen_z - 1 if @picture.number >=
  Spriteset_Map::FIRST_PICBELOW_ID and @picture.number <= Spriteset_Map::LAST_PICBELOW_ID
  end
end

[Obrazek: aye_furniture_pres.png]
08-04-15 23:35
Znajdź wszystkie posty użytkownika
"Pomógł" przyznał(a):
Wątek zamknięty 


Wiadomości w tym wątku
RE: Postaci nad obrazkami - PaC - 08-04-15, 15:56
RE: Postaci nad obrazkami - Ayene - 08-04-15 23:35
RE: Postaci nad obrazkami - Ayene - 09-04-15, 20:03

Skocz do:


Użytkownicy przeglądający ten wątek: 1 gości

Kontakt | Ultima Forum | Wróć do góry | Wróć do forów | Wersja bez grafiki | RSS
Powered By MyBB. © 2013 MyBB Group. All Rights Reserved.
Skórka by Ayene.