Vai al contenuto


Toggle Chat RM - Chat Apri la Chat in un popup

E' severamente vietato richiedere supporto su RPG Maker in chat!
@  Caba33akaMimik : (25 May 2012 - 09:56 PM) sera a tutti ^^
@  Melosx : (25 May 2012 - 08:30 PM) Buonasera a tutti
@  Hashmin : (25 May 2012 - 02:15 PM) ciao a tt!
@  Pech93 : (24 May 2012 - 01:55 PM) ho aggiunto delle composizioni originali!!! Chi le vuole ascoltare e dare qualche commento costruttivo?
@  MihaChan : (23 May 2012 - 09:19 PM) a parte i denti -che stanno decidendo di darmi noia in questi giorni-, tutto okay~
@  Melosx : (23 May 2012 - 09:18 PM) bene ^.^ ... Tu??
@  MihaChan : (23 May 2012 - 09:17 PM) come va? xD
@  MihaChan : (23 May 2012 - 09:16 PM) okay
@  MihaChan : (23 May 2012 - 09:16 PM) ah
@  Melosx : (23 May 2012 - 09:14 PM) ciao miha... ai dont spic inglisc
@  MihaChan : (23 May 2012 - 09:12 PM) how'sa goin'?
@  MihaChan : (23 May 2012 - 09:12 PM) ciao Mel!
@  Melosx : (23 May 2012 - 09:07 PM) ciao
@  MihaChan : (23 May 2012 - 09:06 PM) salve D:
@  Pech93 : (23 May 2012 - 08:05 PM) MIk?
@  Melosx : (23 May 2012 - 07:51 PM) VIENI SU MSN!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@  Melosx : (23 May 2012 - 07:51 PM) MIIIIIIIIIIIIIIIIIIIKKKKKKKKKKKK!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@  Melosx : (23 May 2012 - 07:46 PM) *iù
@  Melosx : (23 May 2012 - 07:38 PM) iu spin mi rai rau bebi rai rau laic a record bebi rau rau rau rau
@  Melosx : (23 May 2012 - 07:37 PM) lalalallalallalallallllllllllalalalallaaaaaaaaaaaaaaaaaaaaaa!!!!!!!!!!!!!!!!!!

SwapXT


  • Per cortesia connettiti per rispondere
36 risposte a questa discussione

#1 OFFLINE   Ally

Ally

    Fondatori

  • Amministratori
  • 5558 Messaggi:
  • Localitàrpgmkr
  • Ruolo:
    Scripter
  • Progetto VX:
    Essence
  • Tool:
    RM2k/2k3

Inviato 13 August 2010 - 01:58 AM

SwapTX
Immagine inserita
L'applicazione definitiva per cambiare tileset/passaggi più semplicemente!!!


Nome Script: SwapXT
Versione: 1.0
Autore/i: BulletXT

Informazioni:
Con questo script e programma,possiamo utilizzare quanti tileset vogliamo troncando nettamente la limitazione impostata sul VX.
Dalla versione precedente,questa ha subito una forte miglioria,diventando l'applicazione definitiva =)

Screenshots:
Spoiler

Istruzioni:
- Scaricare ed inserite lo script nel vostro progetto
- Scaricare ed installate il programma
- Una volta aperto il programma vi verrà chiesto di scegliere il progetto che volete modificare selezionando il file Game.ini
- Ora inserite tutti i tileset che volete cambiare creando una cartella in Graphics/System /extra_tiles
- Utilizzare le prime due schede del programma per cambiare tileset/passabilità per poi mappare
- Utilizzare la terza scheda per applicare lo swap a un'ID mappa e modificare quelle esistenti
- Utilizzare la terza scheda per swappare i tile in tempo reale

Script:
=begin
                                SwapXT

Version: 1.0
Author: Marco Di Antonio (bulletxt@gmail.com)
Nickname: BulletXt
Date: 14/07/2010

This is SwapXT script that must be put in your VX game script section.
It's Plug&Play.
Use SwapXT application to do swaps once you put this into your VX game.

=end


############################# CONFIGURATION ####################################

#Switch ID.
#If ON, your events will not swap according to tiles and will use default tiles.
DISABLE_EVENT_SWAPPING = 100


=begin
IGNORE the following two switches IDs unless you are using
old 0.4 swapping script found at:
http://lodestone2d.svn.sourceforge.net/viewvc/lodestone2d/Scripts-Dev/Swap_TileSet/Swap_tile_new_passage_setting.rb .
If you are, set the 2 ID switches to ensure compatibility
with your current "old system" swaps.
The meaning of these two switches are described on the old 0.4 script, and you
should already have confidence with them if you need these.
=end
SWAP_TILE = 9999
LOAD_PASSAGE_SETTING = 9998


########################## END CONFIGURATION ###################################


#==============================================================================
# ** Cache

module Cache_Swap_Tiles

  #error message in case user is swapping tiles
  #on a map with both old and new system
  def self.error_message(map_id)
  $bulletxt_error_message_mixed_swapping_configuration = "BulletXt Message: 
  on this map ID " + map_id.to_s() + " 
  you have a dangerous configuration.
  You are swapping tilesets from events and from the swapping application. 
  Mixed configuration is not allowed. 
  Please decide which system to use to swap your tiles. 
  I highly suggest to swap tilesets using the swapping application. 
  If you decide to do this, please be sure you turn off the swapping switch
  ID " + SWAP_TILE.to_s() + " before entering this map. 
  I will close the game for security reasons."  
  #get rid of n
  array = $bulletxt_error_message_mixed_swapping_configuration.split("n")
  size = array.length()
  n = 0
  f = ""
  while n < size do
    message = array[n] 
    f = f + message
    n = n + 1
  end
  $bulletxt_error_message_mixed_swapping_configuration = f
  end

  #error message in case user is swapping passage settings
  #on a map with both old and new system
  def self.error_message_passage(map_id)
  $bulletxt_error_message_mixed_swapping_configuration = "BulletXt Message: 
  on this map ID " + map_id.to_s() + " 
  you have a dangerous configuration.
  You are swapping a passage settings from events and from the swapping application. 
  Mixed configuration is not allowed. 
  Please decide which system to use to swap your passage settings. 
  I highly suggest to swap passage settings using the swapping application. 
  If you decide to do this, please be sure you turn off the swapping passage
  setting switch ID " + LOAD_PASSAGE_SETTING.to_s() + " before entering this map. 
  I will close the game for security reasons."  
  #get rid of n
  array = $bulletxt_error_message_mixed_swapping_configuration.split("n")
  size = array.length()
  n = 0
  f = ""
  while n < size do
    message = array[n] 
    f = f + message
    n = n + 1
  end
  $bulletxt_error_message_mixed_swapping_configuration = f
  end  


  #--------------------------------------------------------------------------
  # * Get Character Graphic
  #     filename : Filename
  #--------------------------------------------------------------------------
  def self.swap(filename)
    load_bitmap("Graphics/System/extra_tiles/", filename)
  end

  #--------------------------------------------------------------------------
  # * Clear Cache
  #--------------------------------------------------------------------------
  def self.clear
    @cache = {} if @cache == nil
    @cache.clear
    GC.start
  end
  #--------------------------------------------------------------------------
  # * Load Bitmap
  #--------------------------------------------------------------------------
  def self.load_bitmap(folder_name, filename, hue = 0)
    @cache = {} if @cache == nil
    path = folder_name + filename
    if not @cache.include?(path) or @cache[path].disposed?
      if filename.empty?
        @cache[path] = Bitmap.new(32, 32)
      else
        @cache[path] = Bitmap.new(path)
      end
    end
    if hue == 0
      return @cache[path]
    else
      key = [path, hue]
      if not @cache.include?(key) or @cache[key].disposed?
        @cache[key] = @cache[path].clone
        @cache[key].hue_change(hue)
      end
      return @cache[key]
    end
  end
end


################################################################################



############ CHECK IF THERE ARE SWAPPED TILES AT START PLAY TIME ###############
=begin
We must ensure user is starting game and there are physically swapped tiles or
passage settings,
tiles that have been for example swapped from the application
=end
class Scene_Title < Scene_Base

  alias swapxt_start start
  def start
    swapxt_start
    check_if_tileset_swapped_exist
    check_if_passage_swapped_exist
  end

  def check_if_tileset_swapped_exist
    tile = "Graphics/System/swapped_"
    tileset_swap_loaded_message_error if FileTest.exist?(tile + "A1.png")
    tileset_swap_loaded_message_error if FileTest.exist?(tile + "A2.png")
    tileset_swap_loaded_message_error if FileTest.exist?(tile + "A3.png")
    tileset_swap_loaded_message_error if FileTest.exist?(tile + "A4.png")
    tileset_swap_loaded_message_error if FileTest.exist?(tile + "A5.png")
    tileset_swap_loaded_message_error if FileTest.exist?(tile + "B.png")
    tileset_swap_loaded_message_error if FileTest.exist?(tile + "C.png")
    tileset_swap_loaded_message_error if FileTest.exist?(tile + "D.png")
    tileset_swap_loaded_message_error if FileTest.exist?(tile + "E.png")
  end

  def tileset_swap_loaded_message_error
    p sprintf("SwapXT Error: You are not allowed to start your game with swapped tilesets. You must unload your tilesets with SwapXT application first. Open SwapXT, click at top Tools->Restore all Tilesets")
    exit
  end

  def check_if_passage_swapped_exist
    passage = "swapxt/passage_warning.stx"
    passage_swap_loaded_message_error if FileTest.exist?(passage)
  end

  def passage_swap_loaded_message_error
    p sprintf("SwapXT Error: You are not allowed to start your game with swapped passage settings. You must unload your passage setting with SwapXT application first. Open SwapXT, go on PassageSetting tab and click on Restore to Default.")
    exit
  end

end
################################################################################



=begin
this class takes care of checking if there is a map id file. this class does
not swap tilesets but only prepares the tiles variables(if map id file found).
this class handles loading the passage setting file, for both old and
new system
=end

class Game_Map
  include Cache_Swap_Tiles  
  alias bulletxt_goodbye_vx_limit_tile_setup setup
  def setup(map_id)

    #must be false at load time
    $swapxt_realtime = false 

    #this variable must always be false at runtime.
    #becomes true only if it finds a map id file
    $swap_tileset_profile_bulletxt = false

    #check if it must load a saved profile TILESET for this map id
    profile_path_tile = "swapxt/tiles/" + map_id.to_s() + ".stx"
    if FileTest.exist?(profile_path_tile)
      #we must now check if user isn't fooling around with his configuration.
      #he must not be swapping tiles on this map with old and new system
      #at the same time. if this is the case, warn him we don't want issues and
      #close the game
      if $game_switches[SWAP_TILE] == true
        Cache_Swap_Tiles.error_message(map_id) 
        p sprintf($bulletxt_error_message_mixed_swapping_configuration)
        exit
      end
      #set this to true so we know we want to swap with new system
      $swap_tileset_profile_bulletxt = true
      #p sprintf(profile_path_tile + " found!")
      #read the map id file, it has 8 lines with the name of the tileset to swap.
      #set each tileset global variable with the corresponding found line, in order.
      $tileA1,$tileA2,$tileA3,$tileA4,$tileA5,$tileB,$tileC,$tileD,$tileE = File.read(profile_path_tile).split("n")
    end


    ##################### SWAP PASSSAGE SETTINGS ##########################
    @swap_passagesetting_bulletxt = false
    #for how this works, look at the code above
    profile_path_passages = "swapxt/passages/" + map_id.to_s() + ".stx"
    if FileTest.exist?(profile_path_passages)
      #p sprintf("passage exists on map " + map_id.to_s())
      if $game_switches[LOAD_PASSAGE_SETTING] == true
        Cache_Swap_Tiles.error_message_passage(map_id) 
        p sprintf($bulletxt_error_message_mixed_swapping_configuration)
        exit
      end
      @swap_passagesetting_bulletxt = true
      $swap_passages = (File.read(profile_path_passages).split("n"))[0]
    end


    #checks if it should load default passage setting, both for old and new system
    if $game_switches[LOAD_PASSAGE_SETTING] == false and @swap_passagesetting_bulletxt == false
      bulletxt_goodbye_vx_limit_tile_setup(map_id) 
      $swap_passages = nil 
      return  
    end


    path = "Graphics/System/extra_tiles/" + $swap_passages.to_s() + ".rvdata" rescue nil

    #check if user set $swap_passages to nil cause he wants to load default setting.
    #if user is loading with new system checks if it's equal to empty::*::
    if $swap_passages == nil or $swap_passages == "empty::*::"
      bulletxt_goodbye_vx_limit_tile_setup(map_id)
      return
    end


    #when here, we are sure user wants to swap passage setting, either
    #via old system or new system
    #the file to swap is not default one, he wants to swap to a real new one
    @map_id = map_id
    @map = load_data(sprintf("Data/Map%03d.rvdata", @map_id))
    @display_x = 0
    @display_y = 0

    # load system settings from that file
    new_system_rvdata = load_data(path)
    # Use passage settings from that file
    @passages = new_system_rvdata.passages

    #default vx code
    referesh_vehicles
    setup_events
    setup_scroll
    setup_parallax
    @need_refresh = false
  end


############################# REAL TIME SWAPS ##################################  
  #if here, player has done a $game_map.tileset call. It must reload
  #map with new passage setting (if it exists) and upate map.
  #OLD SYSTEM
  def tileset
    #if false, we must update and load default passage
    if $game_switches[LOAD_PASSAGE_SETTING] == false
      @passages = $data_system.passages 
    else
      #if nil, must reset passage setting to default  
      if $swap_passages == nil
        @passages = $data_system.passages
        $scene = Scene_Map.new
        return
      end 
    path = "Graphics/System/extra_tiles/" + $swap_passages + ".rvdata" rescue nil
    # load system settings from that file
    new_system_rvdata = load_data(path)
    # Use passage settings from that file
    @passages = new_system_rvdata.passages
    end   
    #this updates the map tiles. it does not modify events or anything else.
    $scene = Scene_Map.new
  end



  #if here, player has done a $game_map.swapxt() call. It must reload
  #map with new passage setting (if it exists) and upate map.
  #NEW SWAPXT SYSTEM
  def swapxt(integer)
    rtx_path = "swapxt/realtime/" + integer.to_s() + ".rtx"
    if !FileTest.exist?(rtx_path )
      p sprintf("SwapXT Error: You have called $game_map.swapxt(" + integer.to_s() + ") , but that Real-Time swap doesn't exist. Please better check it inside SwapXT app, under the Real-Time section.")
      exit
    end
    $tileA1,$tileA2,$tileA3,$tileA4,$tileA5,$tileB,$tileC,$tileD,$tileE,passage = File.read(rtx_path).split("n")
    path = "Graphics/System/extra_tiles/" + passage + ".rvdata" rescue nil
    if !FileTest.exist?(path)
      p sprintf("SwapXT Error: Unable to find " + path + ". Please go and check your existant passages from SwapXT in the PassageSetting section.")
      exit
    end
    $swapxt_realtime = true #warning,realtime update must occur
    # load system settings from that file
    new_system_rvdata = load_data(path)
    # Use passage settings from that file
    @passages = new_system_rvdata.passages
    #this updates the map tiles. it does not modify events or anything else.
    $scene = Scene_Map.new
  end


end


#this class handles loading tilesets
class Spriteset_Map
include Cache_Swap_Tiles  

  alias bulletxt_lodestone_create_tilemap create_tilemap
  def create_tilemap
    #if true, it means the map doesn't have to load tilesets,
    #neither for old swapping system or new system.
    #if true, also means no realtime update occured
    #it must load DEFAULT tilesets
    if $game_switches[SWAP_TILE] == false and $swap_tileset_profile_bulletxt == false and $swapxt_realtime == false
      bulletxt_lodestone_create_tilemap
      $tileA1 = nil
      $tileA2 = nil
      $tileA3 = nil
      $tileA4 = nil
      $tileA5 = nil
      $tileB = nil
      $tileC = nil
      $tileD = nil
      $tileE = nil
      return
    end



=begin
calling the original function is a trick. if there are tiles to swap
it will just replace them, otherwise if a tile is nil it won't swap anything,
but still the tile will be loaded because it has already loaded the original tile
when calling this function. in other words, if setting a tile$n = nil will simply
make the script load default tile.
=end
    bulletxt_lodestone_create_tilemap 
=begin
when here, some/all tiles must be swapped, either old or with new system.
the tile can be equal to "empty::*::" only if it found the file id of the
map and line$n is equal to empty::*::. in that case it must load default tileset.
there are no chances a user with old system is swapping a tileset named
"empty::*::" because you can't name files with ":" characters under
Microsoft Windows OS.
=end
    path_to_graphic = "extra_tiles/" 

    #tileA1
    if $tileA1 == "empty::*::"
      @tilemap.bitmaps[0] = Cache.system("TileA1")
    else
      tile1 = Cache_Swap_Tiles.swap($tileA1 + ".png") rescue nil
      @tilemap.bitmaps[0] = tile1 if $tileA1 != nil
    end

    #tileA2
    if $tileA2 == "empty::*::"
      @tilemap.bitmaps[1] = Cache.system("TileA2")
    else
      tile2 = Cache_Swap_Tiles.swap($tileA2 + ".png") rescue nil
      @tilemap.bitmaps[1] = tile2 if $tileA2 != nil
    end

    #tileA3
    if $tileA3 == "empty::*::"
      @tilemap.bitmaps[2] = Cache.system("TileA3")
    else
      tile3 = Cache_Swap_Tiles.swap($tileA3 + ".png") rescue nil
      @tilemap.bitmaps[2] = tile3 if $tileA3 != nil
    end

    #tileA4
    if $tileA4 == "empty::*::"
      @tilemap.bitmaps[3] = Cache.system("TileA4")
    else
      tile4 = Cache_Swap_Tiles.swap($tileA4 + ".png") rescue nil
      @tilemap.bitmaps[3] = tile4 if $tileA4 != nil
    end

    #tileA5
    if $tileA5 == "empty::*::"
      @tilemap.bitmaps[4] = Cache.system("TileA5")
    else
      tile5 = Cache_Swap_Tiles.swap($tileA5 + ".png") rescue nil
      @tilemap.bitmaps[4] = tile5 if $tileA5 != nil
    end

    #tileB
    if $tileB == "empty::*::"
      @tilemap.bitmaps[5] = Cache.system("TileB")
    else
      tile6 = Cache_Swap_Tiles.swap($tileB + ".png") rescue nil
      @tilemap.bitmaps[5] = tile6 if $tileB != nil
    end

    #tileC
    if $tileC == "empty::*::"
      @tilemap.bitmaps[6] = Cache.system("TileC")
    else
      tile7 = Cache_Swap_Tiles.swap($tileC + ".png") rescue nil
      @tilemap.bitmaps[6] = tile7 if $tileC != nil
    end

    #tileD
    if $tileD == "empty::*::"
      @tilemap.bitmaps[7] = Cache.system("TileD")
    else
      tile8 = Cache_Swap_Tiles.swap($tileD + ".png") rescue nil
      @tilemap.bitmaps[7] = tile8 if $tileD != nil
    end

    #tileE
    if $tileE == "empty::*::"
      @tilemap.bitmaps[8] = Cache.system("TileE")
    else
      tile9 = Cache_Swap_Tiles.swap($tileE + ".png") rescue nil
      @tilemap.bitmaps[8] = tile9 if $tileE != nil
    end

  #closes def
  end
#closes class
end


########################## SWAP EVENT'S GRAPHICS #############################
#the following class handles swapping event's graphics according to the tiles
class Sprite_Character < Sprite_Base
include Cache_Swap_Tiles

  alias swap_tileset_bitmap tileset_bitmap
  def tileset_bitmap(tile_id)
     #do not swap events if true
     if $game_switches[DISABLE_EVENT_SWAPPING]
        set_number = tile_id / 256
        return Cache.system("TileB") if set_number == 0
        return Cache.system("TileC") if set_number == 1
        return Cache.system("TileD") if set_number == 2
        return Cache.system("TileE") if set_number == 3
        return nil
        return 
     end

     if $game_switches[SWAP_TILE] == false and $swap_tileset_profile_bulletxt == false and $swapxt_realtime == false
        set_number = tile_id / 256
        return Cache.system("TileB") if set_number == 0
        return Cache.system("TileC") if set_number == 1
        return Cache.system("TileD") if set_number == 2
        return Cache.system("TileE") if set_number == 3
        return nil
        return 
     end

    swap_tileset_bitmap(tile_id)
    set_number = tile_id / 256

    if $tileB == "empty::*::"
      return Cache.system("TileB") if set_number == 0
    else
      return Cache_Swap_Tiles.swap($tileB) if set_number == 0 rescue nil
    end

    if $tileC == "empty::*::"
      return Cache.system("TileC") if set_number == 1
    else
      return Cache_Swap_Tiles.swap($tileC) if set_number == 1 rescue nil
    end

    if $tileD == "empty::*::"
      return Cache.system("TileD") if set_number == 2
    else
      return Cache_Swap_Tiles.swap($tileD) if set_number == 2 rescue nil
    end

    if $tileE == "empty::*::"
      return Cache.system("TileE") if set_number == 3
    else
       return Cache_Swap_Tiles.swap($tileE) if set_number == 3 rescue nil
    end

    return nil
  end
end



=begin
saves tiles and passage setting variables,
needed if you save on a map that has swapped stuff.
this is only needed when using old system, because new system
reads the value from the map id file
=end
class Scene_File < Scene_Base
  alias bulletxt_swap_tiles_write_save_data write_save_data
  def write_save_data(file)
    bulletxt_swap_tiles_write_save_data(file)
    Marshal.dump($tileA1,      file)
    Marshal.dump($tileA2,      file)
    Marshal.dump($tileA3,      file)
    Marshal.dump($tileA4,      file)
    Marshal.dump($tileA5,      file)
    Marshal.dump($tileB,      file)
    Marshal.dump($tileC,      file)
    Marshal.dump($tileD,      file)
    Marshal.dump($tileE,      file)
    Marshal.dump($swap_passages.to_s(),   file)
    Marshal.dump($swap_tileset_profile_bulletxt,  file)
    Marshal.dump($swapxt_realtime, file)
  end  

  alias bulletxt_swap_tiles_read_save_data read_save_data
  def read_save_data(file)
    bulletxt_swap_tiles_read_save_data(file)
    $tileA1        = Marshal.load(file)
    $tileA2        = Marshal.load(file)
    $tileA3        = Marshal.load(file)
    $tileA4        = Marshal.load(file)
    $tileA5        = Marshal.load(file)
    $tileB        = Marshal.load(file)
    $tileC        = Marshal.load(file)
    $tileD        = Marshal.load(file)
    $tileE        = Marshal.load(file) 
    $swap_passages = Marshal.load(file)
    $swap_tileset_profile_bulletxt = Marshal.load(file)
    $swapxt_realtime = Marshal.load(file)
  end

end

Demo:
http://www.mediafire...g2mg7nkp6fy1nax

Incompatibilità:
Incompatibile con lo script Wall Tile Extension.
Compatibile con la versione precedente di swap.
Immagine inserita
Spoiler

#2 OFFLINE   herupty

herupty

    Apprendista Maker

  • Utenti RM
  • 640 Messaggi:
  • LocalitàMilano
  • Tool:
    S.E.R.P.E. ;P

Inviato 13 August 2010 - 08:26 AM

ottimo, l'ho appena messo in un altro proj per provarlo ed è strafigherrimo (o.O)
complimenti a marco (BulletXt)
e
a te perchè l'hai messo sul forum
lool
Spoiler

#3 OFFLINE   lifaen

lifaen

    Maker Viandante

  • Utenti RM
  • 123 Messaggi:
  • Progetto XP:
    Mimesis
  • Progetto VX:
    Mimesis

Inviato 14 January 2011 - 04:46 PM

Temo mi sia sfuggita una cosa.
Per modificare le varie passabilità come faccio? Cioè, applicare passabilità differenti a tileset differenti?

#4 OFFLINE   Ally

Ally

    Fondatori

  • Amministratori
  • 5558 Messaggi:
  • Localitàrpgmkr
  • Ruolo:
    Scripter
  • Progetto VX:
    Essence
  • Tool:
    RM2k/2k3

Inviato 14 January 2011 - 05:14 PM

Devi impostare le passabilità ovviamente nel tileset e nella scheda Passage Settings setti il nome al tileset che vuoi swappare (così da ricordarti che è quello e così da assegnarlo all'ID della mappa).
Poi salvi il progetto (nel caso te lo dice il programma stesso) così da memorizzare le passabilità e far ritornare quelle originali una volta riavviato il programma (che fa in automatico).
Non è difficile, bisogna solo provare ^^

Il mio consiglio è quello di tenere dei tileset che vanno da A1 a B (inteso come quelli più usati) e di cambiare poi solo i C e i D.
Se poi si ha necessità di cambiare terreni etc su determinate mappe, si può fare comunque tranquillamente ;)
Immagine inserita
Spoiler

#5 OFFLINE   Sleipnir

Sleipnir

    RM Utente

  • Utenti RM
  • StellettaStelletta
  • 12 Messaggi:
  • Progetto VX:
    Eternal slaughter

Inviato 02 March 2011 - 03:39 AM

Sto scaricando tutto,se riscontro problemi faccio sapere,comunque è una cosa geniale!!!
thumbs up!!!
John: "Olympus, per favore"Operatore :"Un attimo, per favore..."Nixon: "Che succede?"John: "Signor Presidente, è in atto una crisi qui, a Los Angeles"Nixon: "Che tipo di crisi?"John: "Siamo senza carta igienica, Signor Presidente."

#6 OFFLINE   Ally

Ally

    Fondatori

  • Amministratori
  • 5558 Messaggi:
  • Localitàrpgmkr
  • Ruolo:
    Scripter
  • Progetto VX:
    Essence
  • Tool:
    RM2k/2k3

Inviato 02 March 2011 - 03:57 AM

Sleipnir, dice:

Sto scaricando tutto,se riscontro problemi faccio sapere,comunque è una cosa geniale!!!
thumbs up!!!
L'uso del programmino è facilissimo una volta capita la meccanica, e ti assicuro che funziona a meraviglia =)
E' stato uno dei motivi su cui mi sono soffermato a portare avanti il mio progetto e a non trasportarlo su XP rifacendo così tutto d'accapo.

Se hai poi problemi sul suo uso, siamo qui =)
Immagine inserita
Spoiler

#7 OFFLINE   Sleipnir

Sleipnir

    RM Utente

  • Utenti RM
  • StellettaStelletta
  • 12 Messaggi:
  • Progetto VX:
    Eternal slaughter

Inviato 02 March 2011 - 05:10 AM

Ok come c'era da aspettarselo da me ho un leggero problemino XD

Ho fatto tutto e mi funziona,ho inserito un tileset al posto della E che normalmente è vuoto,mi spunta nel programmino,posiziono tutto,salvo,spengo SwapXT ma se poi riapro rpg maker non c'è quello che messo,perchè il tileset da me inserito non rimane in memoria,infatti se vado su E non c'è nulla...però se aprò SwapXT e ricarico il programma con SwapXT attivo c'è di nuovo tutto....Cosa posso sbagliare se mi accade ciò?

Spero di essermi spiegato in modo comprensibile,l'ora inizia ad essere tarda e la mente offuscata XD
John: "Olympus, per favore"Operatore :"Un attimo, per favore..."Nixon: "Che succede?"John: "Signor Presidente, è in atto una crisi qui, a Los Angeles"Nixon: "Che tipo di crisi?"John: "Siamo senza carta igienica, Signor Presidente."

#8 OFFLINE   Ally

Ally

    Fondatori

  • Amministratori
  • 5558 Messaggi:
  • Localitàrpgmkr
  • Ruolo:
    Scripter
  • Progetto VX:
    Essence
  • Tool:
    RM2k/2k3

Inviato 02 March 2011 - 10:32 PM

Sleipnir, dice:

Ok come c'era da aspettarselo da me ho un leggero problemino XD

Ho fatto tutto e mi funziona,ho inserito un tileset al posto della E che normalmente è vuoto,mi spunta nel programmino,posiziono tutto,salvo,spengo SwapXT ma se poi riapro rpg maker non c'è quello che messo,perchè il tileset da me inserito non rimane in memoria,infatti se vado su E non c'è nulla...però se aprò SwapXT e ricarico il programma con SwapXT attivo c'è di nuovo tutto....Cosa posso sbagliare se mi accade ciò?

Spero di essermi spiegato in modo comprensibile,l'ora inizia ad essere tarda e la mente offuscata XD
Non sbagli nulla, il programma ti consente di caricare i tileset che vuoi cambiare, ma senza compromettere quelli originali.
Infatti nella cartella del tuo game, noterai che ci sono dei file di salvataggio dello swap.
Immagine inserita
Spoiler

#9 OFFLINE   heisenman

heisenman

    Recensori

  • Recensori
  • 136 Messaggi:
  • Tool:
    VX

Inviato 03 March 2011 - 03:41 PM

Citazione

se poi riapro rpg maker non c'è quello che messo,perchè il tileset da me inserito non rimane in memoria,infatti se vado su E non c'è nulla
In pratica il programma è diviso in due, una parte ti fa vedere i tiles "swappati" nell'editor mentre mappi, ma non salva niente, è solo una comodità visiva.
L'altra parte, quella effettiva, è quella che salva i tiles ed i passage settings nelle mappe nel gioco.

#10 OFFLINE   Sleipnir

Sleipnir

    RM Utente

  • Utenti RM
  • StellettaStelletta
  • 12 Messaggi:
  • Progetto VX:
    Eternal slaughter

Inviato 05 March 2011 - 01:12 AM

OLE OLE OLE OLE OLE OLE OLE OLEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE!!

Scusate ma finalmente ho capito dove sbagliavo,sono un tonto! :risat:

FUNZIONA A MERAVIGLIA!
John: "Olympus, per favore"Operatore :"Un attimo, per favore..."Nixon: "Che succede?"John: "Signor Presidente, è in atto una crisi qui, a Los Angeles"Nixon: "Che tipo di crisi?"John: "Siamo senza carta igienica, Signor Presidente."

#11 OFFLINE   Melosx

Melosx

    Maker di rpgmkr.net

  • RM-Dreamers
  • 895 Messaggi:
  • LocalitàAvola
  • Ruolo:
    Scripter
  • Progetto Ace:
    Menu Chora
  • Tool:
    RPG Maker VX/VX Ace

Inviato 07 March 2011 - 03:07 PM

Buongiorno gente... Potete spiegarmi come fare lo swap istantaneo?? Perchè io con il programma mi creo il call script da mettere nell'evento faccio l'evento ma ottengo il seguente errore:

NoMethodError occurred while runnign script.
undefined method 'swapxt' for #

Il call script è:
$game_map.swapxt(6334) che swappa TileA3, A4, C e i passaggi...
Sicuramente sbaglio io qualcosa... ma cosa??
Immagine inserita
Immagine inserita
Immagine inserita
Immagine inserita

Immagine inserita
Immagine inserita

Targhette vinte nei contest
Spoiler

from skype with love
Spoiler

#12 OFFLINE   heisenman

heisenman

    Recensori

  • Recensori
  • 136 Messaggi:
  • Tool:
    VX

Inviato 07 March 2011 - 04:45 PM

Probabilmente hai dimenticato di inserire lo script nel progetto, è un file chiamato SwapXT.rb, lo devi aprire con NotePad e copiaincollarlo come un normale script.

#13 OFFLINE   Sleipnir

Sleipnir

    RM Utente

  • Utenti RM
  • StellettaStelletta
  • 12 Messaggi:
  • Progetto VX:
    Eternal slaughter

Inviato 07 March 2011 - 05:14 PM

in caso dovessi continuare ad avere difficoltà cè un video su youtube che lo spiega benone
John: "Olympus, per favore"Operatore :"Un attimo, per favore..."Nixon: "Che succede?"John: "Signor Presidente, è in atto una crisi qui, a Los Angeles"Nixon: "Che tipo di crisi?"John: "Siamo senza carta igienica, Signor Presidente."

#14 OFFLINE   Melosx

Melosx

    Maker di rpgmkr.net

  • RM-Dreamers
  • 895 Messaggi:
  • LocalitàAvola
  • Ruolo:
    Scripter
  • Progetto Ace:
    Menu Chora
  • Tool:
    RPG Maker VX/VX Ace

Inviato 07 March 2011 - 05:23 PM

Certo che ho messo lo script se no nn mi funzionerebbe l'altro metodo per swappare(quello prima del trasferimento). L'ho preso dalla demo dello swapxt.
Immagine inserita
Immagine inserita
Immagine inserita
Immagine inserita

Immagine inserita
Immagine inserita

Targhette vinte nei contest
Spoiler

from skype with love
Spoiler

#15 OFFLINE   heisenman

heisenman

    Recensori

  • Recensori
  • 136 Messaggi:
  • Tool:
    VX

Inviato 07 March 2011 - 05:36 PM

Citazione

L'ho preso dalla demo dello swapxt.
Quella del primo post?

#16 OFFLINE   Melosx

Melosx

    Maker di rpgmkr.net

  • RM-Dreamers
  • 895 Messaggi:
  • LocalitàAvola
  • Ruolo:
    Scripter
  • Progetto Ace:
    Menu Chora
  • Tool:
    RPG Maker VX/VX Ace

Inviato 07 March 2011 - 07:41 PM

Lo script che ho è questo qui:
=begin
                    Swap Tileset with new passage setting

Version: 0.4
Author: BulletXt (bulletxt@gmail.com)
Date: 13/06/2009

This scripts makes you:

a) Swap a tileset at any time
b) you can swap all tilesets or n tilesets
c) you can load a new passage setting any time you want

How it works:
Create a folder named "extra_tiles" inside Graphics/System. Place your new
tilesets there. They can be named as you like. Before doing a map transfer,
do a simple callscript inside the event like this:
$tileA1 = "fileName"

Replace "fileName" with the tileset you want to change. In that example,
it will swap tile set A1. You can swap all tilesets or just some of them.
For example you can swap TileA1, TileA4 and TileE doing as said above:
$tileA1 = "fileName"
$tileA4 = "fileName"
$tileE = "fileName"


Immediately after the script call/s inside event,
turn the SWAP_TILE switch ON (this can be set below). To reset default
tileset, before a map transfer simply turn the switch to OFF.


This said, you can also load a new passage setting.
Simply open a new project, set the passagesettings as you want, save and close.
Get into Data folder and copy System.rvdata to your real project. Paste it always
inside "extra_tiles" and rename it to anything you want. Be sure file extension
ends with ".rvdata" .
Example: System.rvdata is renamed to:  pub.rvdata

Passage setting gets loaded exactly like tilesets, this means that first you
do the script call inside event and then you turn the
LOAD_PASSAGE_SETTING switch ON(this can be set below). You can
load a new passage setting without swapping any tiles. The 2 things are totally
indipendent.
The script call to load a passage setting is like this:
$swap_passages = "filePassage"
Replace filePassage with the passage setting file you want to load.


By simply turning both switches to OFF,
you automatically reset passage setting to default one and reset all
tilesets to default.
If instead you want to do a map transfer and keep your swapped tilesets
but want to reset only TileA3,simply do a script call of this type:
$tileA3 = nil
Same behaviour is for passage setting, simply set:
$swap_passages = nil
and that will reset passage setting to default.


Tricks:

- you can create a special effect as seen in the demo.
  For example, you can make a tile swap without
  doing a map transfer. You can for instance make a wall change real time its
  tile! To do this, do the normal call for swapping (callscript + switch ON),
  then immediatley after do this callscript: $game_map.tileset
  This callscript will reload the map (screen freezes for 30 milliseconds) so
  the final effect is that the wall has magically a new tile!
  Same thing is for passagesetting, you can load a new passage setting in real
  time by simply doing (callscript + switch ON) and then $game_map.tileset.

=end


############################# CONFIGURATION ####################################

# This is a switch ID, if ON it calls the swapping system. This is
# used for swapping/resetting tile sets. THIS DOES NOT CHANGE PASSAGE SETTINGS.
# Be sure to turn the switch ON only after doing the callscript (as said above).
SWAP_TILE = 501

# This is a switch ID, if ON it calls the passage setting system. This is
# used for loading/resetting new passage settings. 
# THIS DOES NOT SWAP TILE SETS.
# Be sure to turn the switch ON only after doing the callscript (as said above).
LOAD_PASSAGE_SETTING = 502


########################## END CONFIGURATION ###################################


#==============================================================================
# ** Cache

module Cache_Swap_Tiles
 
  #--------------------------------------------------------------------------
  # * Get Character Graphic
  #     filename : Filename
  #--------------------------------------------------------------------------
  def self.swap(filename)
    load_bitmap("Graphics/System/extra_tiles/", filename)
  end
  
  #--------------------------------------------------------------------------
  # * Clear Cache
  #--------------------------------------------------------------------------
  def self.clear
    @cache = {} if @cache == nil
    @cache.clear
    GC.start
  end
  #--------------------------------------------------------------------------
  # * Load Bitmap
  #--------------------------------------------------------------------------
  def self.load_bitmap(folder_name, filename, hue = 0)
    @cache = {} if @cache == nil
    path = folder_name + filename
    if not @cache.include?(path) or @cache[path].disposed?
      if filename.empty?
        @cache[path] = Bitmap.new(32, 32)
      else
        @cache[path] = Bitmap.new(path)
      end
    end
    if hue == 0
      return @cache[path]
    else
      key = [path, hue]
      if not @cache.include?(key) or @cache[key].disposed?
        @cache[key] = @cache[path].clone
        @cache[key].hue_change(hue)
      end
      return @cache[key]
    end
  end
end






#initialize global variables
$tileA1 = nil
$tileA2 = nil
$tileA3 = nil
$tileA4 = nil
$tileA5 = nil
$tileB = nil
$tileC = nil
$tileD = nil
$tileE = nil
$swap_passages = nil
################################################################################
class Game_Map
include Cache_Swap_Tiles  
  alias bulletxt_goodbye_vx_limit_tile_setup setup
  def setup(map_id)
    #if false, normal vx behavior and exit
    if $game_switches[LOAD_PASSAGE_SETTING] == false
    bulletxt_goodbye_vx_limit_tile_setup(map_id) 
    $swap_passages = nil 
    return  
    end
    
 
    path = "Graphics/System/extra_tiles/" + $swap_passages.to_s() + ".rvdata" rescue nil

   if $swap_passages != nil

     @map_id = map_id
     @map = load_data(sprintf("Data/Map%03d.rvdata", @map_id))
     @display_x = 0
     @display_y = 0
     
     
      # load system settings from that file
      new_system_rvdata = load_data(path)
      # Use passage settings from that file
      @passages = new_system_rvdata.passages
      
      #default vx code
      referesh_vehicles
      setup_events
      setup_scroll
      setup_parallax
      @need_refresh = false
      
    else
    bulletxt_goodbye_vx_limit_tile_setup(map_id)  
    end
   
  end
  
  #if here, player has done a $game_map.tileset call. It must reload
  #map with new passage setting (if it exists) and upate map.
  def tileset
    #if false, we must update and load default passage
    if $game_switches[LOAD_PASSAGE_SETTING] == false
    @passages = $data_system.passages 
    else
    
    #if nil, must reset passage setting to default  
    if $swap_passages == nil
    @passages = $data_system.passages
    $scene = Scene_Map.new
    return
    end 
      
      
path = "Graphics/System/extra_tiles/" + $swap_passages + ".rvdata" rescue nil
    
    # load system settings from that file
    new_system_rvdata = load_data(path)
    # Use passage settings from that file
    @passages = new_system_rvdata.passages
   
      
   end   
   #this updates the map tiles. it does not modify events or anything else.
   $scene = Scene_Map.new
  end
  
  
  
end



class Spriteset_Map
include Cache_Swap_Tiles  
  alias bulletxt_lodestone_create_tilemap create_tilemap
  def create_tilemap
    if $game_switches[SWAP_TILE] == false
     bulletxt_lodestone_create_tilemap
     $tileA1 = nil
     $tileA2 = nil
     $tileA3 = nil
     $tileA4 = nil
     $tileA5 = nil
     $tileB = nil
     $tileC = nil
     $tileD = nil
     $tileE = nil
    else 
bulletxt_lodestone_create_tilemap 
path_to_graphic = "extra_tiles/" 

#tileA1   
tile1 = Cache_Swap_Tiles.swap($tileA1 + ".png") rescue nil
@tilemap.bitmaps[0] = tile1 if $tileA1 != nil#if FileTest.exist?(path_to_graphic + $tileA1.to_s() + ".png")
#tileA2
tile2 = Cache_Swap_Tiles.swap($tileA2 + ".png") rescue nil
@tilemap.bitmaps[1] = tile2 if $tileA2 != nil#if FileTest.exist?(path_to_graphic + $tileA2.to_s() + ".png")
#tileA3
tile3 = Cache_Swap_Tiles.swap($tileA3 + ".png") rescue nil
@tilemap.bitmaps[2] = tile3 if $tileA3 != nil#if FileTest.exist?(path_to_graphic + $tileA3.to_s() + ".png")
#tileA4
tile4 = Cache_Swap_Tiles.swap($tileA4 + ".png") rescue nil
@tilemap.bitmaps[3] = tile4 if $tileA4 != nil#if FileTest.exist?(path_to_graphic + $tileA4.to_s() + ".png")
#tileA5
tile5 = Cache_Swap_Tiles.swap($tileA5 + ".png") rescue nil
@tilemap.bitmaps[4] = tile5 if $tileA5 != nil#if FileTest.exist?(path_to_graphic + $tileA5.to_s() + ".png")
#tileB
tile6 = Cache_Swap_Tiles.swap($tileB + ".png") rescue nil
@tilemap.bitmaps[5] = tile6 if $tileB != nil#if FileTest.exist?(path_to_graphic + $tileB.to_s() + ".png")
#tileC
tile7 = Cache_Swap_Tiles.swap($tileC + ".png") rescue nil
@tilemap.bitmaps[6] = tile7 if $tileC != nil#if FileTest.exist?(path_to_graphic + $tileC.to_s() + ".png")
#tileD
tile8 = Cache_Swap_Tiles.swap($tileD + ".png") rescue nil
@tilemap.bitmaps[7] = tile8 if $tileD != nil#if FileTest.exist?(path_to_graphic + $tileD.to_s() + ".png")
#tileE
tile9 = Cache_Swap_Tiles.swap($tileE + ".png") rescue nil
@tilemap.bitmaps[8] = tile9 if $tileE != nil#if FileTest.exist?(path_to_graphic + $tileE.to_s() + ".png")    

    
    end

  end

end



class Scene_File < Scene_Base
  alias bulletxt_swap_tiles_write_save_data write_save_data
  def write_save_data(file)
    bulletxt_swap_tiles_write_save_data(file)
    Marshal.dump($tileA1,      file)
    Marshal.dump($tileA2,      file)
    Marshal.dump($tileA3,      file)
    Marshal.dump($tileA4,      file)
    Marshal.dump($tileA5,      file)
    Marshal.dump($tileB,      file)
    Marshal.dump($tileC,      file)
    Marshal.dump($tileD,      file)
    Marshal.dump($tileE,      file)
    Marshal.dump($swap_passages.to_s(),   file)
  end  
  
  
  alias bulletxt_swap_tiles_read_save_data read_save_data
  def read_save_data(file)
    bulletxt_swap_tiles_read_save_data(file)
    $tileA1        = Marshal.load(file)
    $tileA2        = Marshal.load(file)
    $tileA3        = Marshal.load(file)
    $tileA4        = Marshal.load(file)
    $tileA5        = Marshal.load(file)
    $tileB        = Marshal.load(file)
    $tileC        = Marshal.load(file)
    $tileD        = Marshal.load(file)
    $tileE        = Marshal.load(file) 
    $swap_passages = Marshal.load(file)
  end
  
  
  
  end

Immagine inserita
Immagine inserita
Immagine inserita
Immagine inserita

Immagine inserita
Immagine inserita

Targhette vinte nei contest
Spoiler

from skype with love
Spoiler

#17 OFFLINE   Melosx

Melosx

    Maker di rpgmkr.net

  • RM-Dreamers
  • 895 Messaggi:
  • LocalitàAvola
  • Ruolo:
    Scripter
  • Progetto Ace:
    Menu Chora
  • Tool:
    RPG Maker VX/VX Ace

Inviato 05 April 2011 - 08:28 PM

rieccomi a rompere... Ho sostituito alla versione 0.4 la versione 1.0 dello script ma i passaggi settati con la vecchia 0.4 non mi funzionano più... c'è qualche differenza nel settare i passaggi tra òle due versioni??
Immagine inserita
Immagine inserita
Immagine inserita
Immagine inserita

Immagine inserita
Immagine inserita

Targhette vinte nei contest
Spoiler

from skype with love
Spoiler

#18 OFFLINE   lifaen

lifaen

    Maker Viandante

  • Utenti RM
  • 123 Messaggi:
  • Progetto XP:
    Mimesis
  • Progetto VX:
    Mimesis

Inviato 06 April 2011 - 04:56 PM

Credo di non aver ancora ben chiaro il concetto del passage setting... -.-''
O meglio. Da quello che ho capito serve per avere passabilità diverse su mappe diverse, no?
Per esempio: supponiamo che io abbia due mappe A e B. Nella A utilizzo un tile diverso da quello che utilizzo nella mappa B, quindi ho bisogno di settare due passabilità differenti.
Se fino qui è giusto...come procedo poi? Perchè se cambio passage setting la mappa mi scompare? O.o

#19 OFFLINE   Ally

Ally

    Fondatori

  • Amministratori
  • 5558 Messaggi:
  • Localitàrpgmkr
  • Ruolo:
    Scripter
  • Progetto VX:
    Essence
  • Tool:
    RM2k/2k3

Inviato 06 April 2011 - 11:34 PM

Citazione

rieccomi a rompere... Ho sostituito alla versione 0.4 la versione 1.0 dello script ma i passaggi settati con la vecchia 0.4 non mi funzionano più... c'è qualche differenza nel settare i passaggi tra òle due versioni??
Non credo °_° Oltre ad un aggiornamento dello script, non è cambiato il programma, ma non ho ancora provato se funziona con una versione già 'avviata'.

Citazione

Credo di non aver ancora ben chiaro il concetto del passage setting... -.-''
O meglio. Da quello che ho capito serve per avere passabilità diverse su mappe diverse, no?
Per esempio: supponiamo che io abbia due mappe A e B. Nella A utilizzo un tile diverso da quello che utilizzo nella mappa B, quindi ho bisogno di settare due passabilità differenti.
Se fino qui è giusto...come procedo poi? Perchè se cambio passage setting la mappa mi scompare? O.o
Questo script/programma, serve proprio per poter usare altri tileset.
Dopo che hai 'swappato' il tileset in questione (quello che userai su quella mappa), gli andrai a cambiare le passailità.
Dopodichè il programma, per poter attuare le modifiche, ti chiede di riavviare il programma.
Riavviato, troverai le passabilità settate su quella mappa.
Immagine inserita
Spoiler

#20 OFFLINE   lifaen

lifaen

    Maker Viandante

  • Utenti RM
  • 123 Messaggi:
  • Progetto XP:
    Mimesis
  • Progetto VX:
    Mimesis

Inviato 08 April 2011 - 07:10 AM

Ce l'ho fatta! =)
Mitico!




1 utente(i) stanno leggendo questa discussione

0 utenti, 1 ospiti, 0 utenti anonimi