Problem solved, for reference to others: http://www.rpgmakervxace.net/topic/31613-something-in-this-short-addon-is-messing-up-the-save-functionhelp/
First off, I understand I'm suppose to post in the script's thread for support for that script. However, I have two legitimate reasons for not doing so:
1. Already did, however I know the scripter hasn't been active lately, and time is of the essence.
2.This is a small add-on to his script, and I can already kinda guess the area where the problem is occurring, however I know absolutely no Ruby syntax.
After fighting a battle using the Theo Battle system - http://forums.rpgmakerweb.com/index.php?/topic/29231-theolized-sideview-battle-system-version-14-patch/
the save function wont work, and it only plays a buzzer.
Not only that, but this addon is also causing this error when I try to equip a weapon after participating in a battle:
"Script 'Window_EquipItem' line 73: TypeError occurred.
no marshal_dump is defined for class Proc"
So, after about a half-hour of using the process of elimination, I found out that one of its add-on scripts is screwing up the save function. Could anyone who knows Ruby syntax help me out here and look through this real quick? It's not too long I promise.
(The section most likely causing the error is highlighted, however any scripter will know better than me whether that's what is in fact causing the problem)
Thanks for anyone willing to take a look at this!
First off, I understand I'm suppose to post in the script's thread for support for that script. However, I have two legitimate reasons for not doing so:
1. Already did, however I know the scripter hasn't been active lately, and time is of the essence.
2.This is a small add-on to his script, and I can already kinda guess the area where the problem is occurring, however I know absolutely no Ruby syntax.
After fighting a battle using the Theo Battle system - http://forums.rpgmakerweb.com/index.php?/topic/29231-theolized-sideview-battle-system-version-14-patch/
the save function wont work, and it only plays a buzzer.
Not only that, but this addon is also causing this error when I try to equip a weapon after participating in a battle:
"Script 'Window_EquipItem' line 73: TypeError occurred.
no marshal_dump is defined for class Proc"
So, after about a half-hour of using the process of elimination, I found out that one of its add-on scripts is screwing up the save function. Could anyone who knows Ruby syntax help me out here and look through this real quick? It's not too long I promise.
(The section most likely causing the error is highlighted, however any scripter will know better than me whether that's what is in fact causing the problem)
#==============================================================================
# TSBS Addon - Basename Changer
# Version : 1.0
# Language : English
# Requires : Theolized SBS version 1.4
#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
# Contact :
#------------------------------------------------------------------------------
# *> http://www.rpgmakerid.com
# *> http://www.rpgmakervxace.net
# *> http://theolized.blogspot.com
#==============================================================================
($imported ||= {})[:TSBS_BaseName] = true
#==============================================================================
# Change Logs:
# -----------------------------------------------------------------------------
# 2014.10.13 - Finished
#==============================================================================
%Q{
=================
||Introduction ||
-----------------
Started from some people who bugging me, "Hey, can you make the battler image
changes when it equipped with different weapon?". At first I refused it since
I believe it will be troublesome. Until I found the 'best' way to overcome
this problem
Well, this script was intended to change the actor graphics when they changed
their equip. Though, I ended up making the actor can be changed when they
met a certain condition. That said, I named this script as 'Basename Changer'
================
|| How to use ||
----------------
Simply put this script below TSBS implementation
Edit the configuration as you fit. Instruction provided below
===================
|| Terms of use ||
-------------------
Credit me, TheoAllen. You are free to edit this script by your own. As long
as you don't claim it yours. For commercial purpose, don't forget to give me
a free copy of the game.
}
#==============================================================================
# Konfigurasi
#==============================================================================
module TSBS
#------------------------------------------------------------------------------
ActorBaseName = {} # <-- Keramat. Jangan disentuh!
#------------------------------------------------------------------------------
# To use this configuration, you must first write is
#
# ActorBaseName [actor_id] = {}
# Replace 'actor_id' with actor ID in the database that you want fluctuates
#
# Then enter the condition in the {} with a format like this
# "Condition" => "battlername"
#
# Example:
# ActorBaseName [1] = {
# 'Weapon_id == 1' => 'EricSword'
#}
#
# If the first actor to bring the weapon with ID 1 then the name will essentially be replaced
# Be EricSword_1, EricSword_2 etc ...
#
# In addition to 'weapon_id' you can also use some other conditions such as
# > shield_id
# > helmet_id
# > armor_id
# > acc_id
#------------------------------------------------------------------------------
#Ninkoro
ActorBaseName[2] = {
"weapon_id == 3" => "NinkoroDSword",
"weapon_id == 4" => "NinkoroDStaff",
"weapon_id == 5" => "NinkoroDShield",
}
#Tomm
ActorBaseName[3] = {
"weapon_id == 1" => "TommUltima",
}
end
#==============================================================================
# Akhir dari konfigurasi
#==============================================================================
#------------------------------------------------------------------------------
# Optimized eval formula ~
#------------------------------------------------------------------------------
def proc_eval(f, id)
(@proc ||= {})[f] ||= eval("lambda { #{f} }")
begin
@proc[f].call
rescue StandardError => err
ErrorSound.play
text = "Theolized SBS : \nBasename Changer Condition check error on Actor" +
" ID : #{id}\n\n" + err.to_s
msgbox text
exit
end
end
if $imported[:TSBS]
class Game_Actor
alias tsbs_ori_base_name base_battler_name
def base_battler_name
return tsbs_ori_base_name unless ActorBaseName.include?(self.id)
namecase = ActorBaseName[id]
namecase.each do |condition, name|
return name if proc_eval(condition, id)
end
return tsbs_ori_base_name
end
#----------------------------------------------------------------------------
# Additional helper methods. Most likely won't works for heavily modified
# custom equip slots
#----------------------------------------------------------------------------
def weapon_id(slot = 0)
return 0 unless weapons[slot]
return weapons[slot].id
end
def weapon_type(slot = 0)
return 0 unless weapons[slot]
return weapons[slot].wtype_id
end
def shield_id
shield = armors.find {|armor| armor && armor.etype_id == 1}
return 0 unless shield
return shield.id
end
def shield_type
shield = armors.find {|armor| armor && armor.etype_id == 1}
return 0 unless shield
return shield.atype_id
end
def helmet_id
helm = armors.find {|armor| armor && armor.etype_id == 2}
return 0 unless helm
return helm.id
end
def helmet_type
helm = armors.find {|armor| armor && armor.etype_id == 2}
return 0 unless helm
return helm.atype_id
end
def armor_id
body = armors.find {|armor| armor && armor.etype_id == 3}
return 0 unless body
return body.id
end
def armor_type
body = armors.find {|armor| armor && armor.etype_id == 3}
return 0 unless body
return body.atype_id
end
def acc_id
acc = armors.find {|armor| armor && armor.etype_id == 4}
return 0 unless acc
return acc.id
end
def acc_type
acc = armors.find {|armor| armor && armor.etype_id == 4}
return 0 unless acc
return acc.atype_id
end
end
end # $imported[:TSBS]
# TSBS Addon - Basename Changer
# Version : 1.0
# Language : English
# Requires : Theolized SBS version 1.4
#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
# Contact :
#------------------------------------------------------------------------------
# *> http://www.rpgmakerid.com
# *> http://www.rpgmakervxace.net
# *> http://theolized.blogspot.com
#==============================================================================
($imported ||= {})[:TSBS_BaseName] = true
#==============================================================================
# Change Logs:
# -----------------------------------------------------------------------------
# 2014.10.13 - Finished
#==============================================================================
%Q{
=================
||Introduction ||
-----------------
Started from some people who bugging me, "Hey, can you make the battler image
changes when it equipped with different weapon?". At first I refused it since
I believe it will be troublesome. Until I found the 'best' way to overcome
this problem
Well, this script was intended to change the actor graphics when they changed
their equip. Though, I ended up making the actor can be changed when they
met a certain condition. That said, I named this script as 'Basename Changer'
================
|| How to use ||
----------------
Simply put this script below TSBS implementation
Edit the configuration as you fit. Instruction provided below
===================
|| Terms of use ||
-------------------
Credit me, TheoAllen. You are free to edit this script by your own. As long
as you don't claim it yours. For commercial purpose, don't forget to give me
a free copy of the game.
}
#==============================================================================
# Konfigurasi
#==============================================================================
module TSBS
#------------------------------------------------------------------------------
ActorBaseName = {} # <-- Keramat. Jangan disentuh!
#------------------------------------------------------------------------------
# To use this configuration, you must first write is
#
# ActorBaseName [actor_id] = {}
# Replace 'actor_id' with actor ID in the database that you want fluctuates
#
# Then enter the condition in the {} with a format like this
# "Condition" => "battlername"
#
# Example:
# ActorBaseName [1] = {
# 'Weapon_id == 1' => 'EricSword'
#}
#
# If the first actor to bring the weapon with ID 1 then the name will essentially be replaced
# Be EricSword_1, EricSword_2 etc ...
#
# In addition to 'weapon_id' you can also use some other conditions such as
# > shield_id
# > helmet_id
# > armor_id
# > acc_id
#------------------------------------------------------------------------------
#Ninkoro
ActorBaseName[2] = {
"weapon_id == 3" => "NinkoroDSword",
"weapon_id == 4" => "NinkoroDStaff",
"weapon_id == 5" => "NinkoroDShield",
}
#Tomm
ActorBaseName[3] = {
"weapon_id == 1" => "TommUltima",
}
end
#==============================================================================
# Akhir dari konfigurasi
#==============================================================================
#------------------------------------------------------------------------------
# Optimized eval formula ~
#------------------------------------------------------------------------------
def proc_eval(f, id)
(@proc ||= {})[f] ||= eval("lambda { #{f} }")
begin
@proc[f].call
rescue StandardError => err
ErrorSound.play
text = "Theolized SBS : \nBasename Changer Condition check error on Actor" +
" ID : #{id}\n\n" + err.to_s
msgbox text
exit
end
end
if $imported[:TSBS]
class Game_Actor
alias tsbs_ori_base_name base_battler_name
def base_battler_name
return tsbs_ori_base_name unless ActorBaseName.include?(self.id)
namecase = ActorBaseName[id]
namecase.each do |condition, name|
return name if proc_eval(condition, id)
end
return tsbs_ori_base_name
end
#----------------------------------------------------------------------------
# Additional helper methods. Most likely won't works for heavily modified
# custom equip slots
#----------------------------------------------------------------------------
def weapon_id(slot = 0)
return 0 unless weapons[slot]
return weapons[slot].id
end
def weapon_type(slot = 0)
return 0 unless weapons[slot]
return weapons[slot].wtype_id
end
def shield_id
shield = armors.find {|armor| armor && armor.etype_id == 1}
return 0 unless shield
return shield.id
end
def shield_type
shield = armors.find {|armor| armor && armor.etype_id == 1}
return 0 unless shield
return shield.atype_id
end
def helmet_id
helm = armors.find {|armor| armor && armor.etype_id == 2}
return 0 unless helm
return helm.id
end
def helmet_type
helm = armors.find {|armor| armor && armor.etype_id == 2}
return 0 unless helm
return helm.atype_id
end
def armor_id
body = armors.find {|armor| armor && armor.etype_id == 3}
return 0 unless body
return body.id
end
def armor_type
body = armors.find {|armor| armor && armor.etype_id == 3}
return 0 unless body
return body.atype_id
end
def acc_id
acc = armors.find {|armor| armor && armor.etype_id == 4}
return 0 unless acc
return acc.id
end
def acc_type
acc = armors.find {|armor| armor && armor.etype_id == 4}
return 0 unless acc
return acc.atype_id
end
end
end # $imported[:TSBS]
Thanks for anyone willing to take a look at this!