How to lock a single character's formation?

Discussion in 'JS Plugin Requests' started by Drago the Shinigami, Dec 11, 2016.

  1. Drago the Shinigami

    Drago the Shinigami The KING of the Shinigami! Member

    Messages:
    25
    Likes Received:
    1
    First Language:
    English
    Primarily Uses:
    RMMV
    Hi! What I'm trying to do is have it so the player cannot change the formation of the main character, but can still change the formation of all the rest. Does anyone know how to do this? A plugin, perhaps?
     
    #1
  2. Andar

    Andar Veteran Veteran

    Messages:
    27,256
    Likes Received:
    6,019
    Location:
    Germany
    First Language:
    German
    Primarily Uses:
    RMMV
    yes, and because it requires a plugin or script this is the wrong place


    I've moved this thread to Plugin Requests. Please be sure to post your threads in the correct forum next time. Thank you.
     
    #2
  3. Drago the Shinigami

    Drago the Shinigami The KING of the Shinigami! Member

    Messages:
    25
    Likes Received:
    1
    First Language:
    English
    Primarily Uses:
    RMMV
    Sorry, I did not know. I am actually kind of new here...
     
    #3
  4. Drago the Shinigami

    Drago the Shinigami The KING of the Shinigami! Member

    Messages:
    25
    Likes Received:
    1
    First Language:
    English
    Primarily Uses:
    RMMV
    So, can anyone help me with this?
     
    #4
  5. Engr. Adiktuzmiko

    Engr. Adiktuzmiko Chemical Engineer, Game Developer, Using BlinkBoy' Veteran

    Messages:
    14,066
    Likes Received:
    2,610
    Location:
    Philippines
    First Language:
    Tagalog
    Try to browse at Yanfly's plugins, I think he has an actor lock script
     
    #5
  6. Shaz

    Shaz Veteran Veteran

    Messages:
    36,991
    Likes Received:
    10,911
    Location:
    Australia
    First Language:
    English
    Primarily Uses:
    RMMV
    Save the following as a new js file (call it whatever you want) in your js/plugins folder and add it to your plugin manager:

    Code:
    Game_Actor.prototype.isFormationChangeOk = function() {
      return !actor.actor().meta.lockFormation;
    }
    then put <lockFormation> in the note tag of any actor you want to lock into place.


    If you try it and it doesn't work or you get an error message, please open the developer tools (F8) and post the console log.  I haven't tested this, but I'm hoping I've got the syntax correct.
     
    #6
  7. Drago the Shinigami

    Drago the Shinigami The KING of the Shinigami! Member

    Messages:
    25
    Likes Received:
    1
    First Language:
    English
    Primarily Uses:
    RMMV
    Thanks! This helps a lot!
     
    #7

Share This Page