Actors name control

This script let you check if actors names have banned words in they.

  1. #==============================================================================
  2. # Actors name control
  3. # By gerkrt/gerrtunk, Heretic86(Idea)
  4. # Version: 1.0
  5. # License: MIT, credits
  6. # Date: 12/07/2011
  7. # IMPORTANT NOTE: to acces the more actualitzed or corrected version of this
  8. # script check here: http://usuarios.multimania.es/kisap/english_list.html
  9. #==============================================================================
  10.  
  11. =begin
  12.  
  13. ------INTRODUCTION------
  14.  
  15. This script let you check if actors names have banned words in they.
  16.  
  17. -------INSTRUCTIONS---------
  18.  
  19. Add any new words in Banned_words list, adding a , 'X' each time.
  20. The switch is actived when the scripts call found what where seeking.
  21. Note that yu can use the scripts in a conditions and efects.
  22.  
  23. is_banned?(actor_id): Call script that check if the actor have a  banned name.
  24.   is_banned?(1) --> check for alexis actor id 1
  25.  
  26. is_word?(actor_id, word): Call script that check if the actors name is the word.
  27.   is_word?(1, 'Wep')  --> check for alexis actor id and the word 'Wep'
  28.  
  29. Note that this script is case unsesitive.
  30. =end
  31.  
  32. module Wep
  33.   Banned_words = 'Wep', 'Joan', 'melodic'
  34.   Switch_for_banned = 1
  35. end
  36.  
  37. class Interpreter
  38.  
  39.   #--------------------------------------------------------------------------
  40.   # * Is banned?
  41.   #--------------------------------------------------------------------------
  42.   def is_banned?(actor_id)
  43.     for bw in Wep::Banned_words
  44.       if bw.upcase == $game_actors[actor_id].name.upcase
  45.         $game_switches[Wep::Switch_for_banned] = true
  46.         return truerir
  47.       end
  48.     end
  49.     return false
  50.   end
  51.  
  52.   #--------------------------------------------------------------------------
  53.   # * Is word?
  54.   #--------------------------------------------------------------------------
  55.   def is_word?(actor_id, bw)
  56.     if bw.upcase == $game_actors[actor_id].name.upcase
  57.       $game_switches[Wep::Switch_for_banned] = true
  58.       return true
  59.     end
  60.     return false
  61.   end
  62.    
  63. end
  64.  
Expand to see the code.
What do you mean banned words?
Words that you dont like or want that the actor have as a name.
He means like "ass", or "shit", or "fuck", which is a pity, since I've always wanted to name a hero Shitty-ass McFuck.
I think that it would be more useful to prevent the player from naming the character the same as other characters in the game. I mean it would be pretty confusing in battles and menus if all your dudes had the same name.
This script was a request, xD, i dont think is a lot useful but... using the name as a playable idea is not that bad and its alot original and immersive... anyway it was for a fun game

Original thread: https://www.hbgames.org/forums/viewtopic.php?t=75071