module RPG class BaseItem def nosense(sense) return self.note.match(sense) end end class State def nosense(sense) return self.note.match(sense) end end end class Game_BattlerBase def no_sense(sense) if actor? return true if armors.any? {|armor| armor.nosense(sense)} return true if self.class.nosense(sense) return true if actor.nosense(sense) return @states.any? {|i| $data_states[i].nosense(sense) } end return false end end class Window_Message < Window_Base def process_escape_character(code, text, pos) case code.upcase when 'B' contents.font.color.alpha = 50 if $game_player.actor.no_sense('') when 'M' bob = obtain_escape_param(text) if bob < $game_party.members.size contents.font.color.alpha = 220 if $game_party.members[bob].no_sense('') elsif bob == 100 contents.font.color.alpha = 220 elsif bob > 100 bob -= 100 contents.font.color.alpha = 220 if $game_actors[bob].no_sense('') end when 'D' contents.font.color.alpha = 50 if $game_player.actor.no_sense('') when '$' @gold_window.open when '.' wait(15) when '|' wait(60) when '!' input_pause when '>' @line_show_fast = true when '<' @line_show_fast = false when '^' @pause_skip = true else super end end def process_normal_character(c, pos) c = gagspeak(c) if contents.font.color.alpha == 220 text_width = text_size(c).width draw_text(pos[:x], pos[:y], text_width * 2, pos[:height], c) pos[:x] += text_width wait_for_one_character end def gagspeak(talk) replacements = { 'a' => 'n', 'b' => 'h', 'c' => 'c', 'd' => 'n', 'e' => 'm', 'f' => 'f', 'g' => 'g', 'h' => 'h', 'i' => 'n', 'j' => 'n', 'k' => 'h', 'l' => 'm', 'm' => 'm', 'n' => 'n', 'o' => 'n', 'p' => 'p', 'q' => 'g', 'r' => 'r', 's' => 'ph', 't' => 'ph', 'u' => 'n', 'v' => 'f', 'w' => 'mm', 'x' => 'gh', 'y' => 'm', 'z' => 'ph', '.' => '!', '?' => '!' } talk.downcase! != nil ? bobby = true : bobby = false bob = talk.gsub(Regexp.union(replacements.keys), replacements) bob = bob.capitalize if bobby return bob end end