1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Color Wars 2014-02-22

Event

  1. Omni
    Requirements:
    Custom Regions In a Box 5.0 (optional)
    Color Wars (beta)

    So this is a simple event with very little setup on the gm's half.

    Just follow this method

    [wallup (spawns some walls to stop fighting)
    [add cw2gate (2 team gate)
    [add cw4gate (4 team gate)
    wait until all players have entered the gate (gm descression timer)
    also allow players to equip the event items
    [walldown (remove the walls so event can start)



    everything else is taken care of the event gates will automaticly teleport players to the CW area
    and the winning stones will automaticly teleport them to fel brit bank

    You can add healers or ankh's within each teams starting location so they can res if you want a longer event and remove them after a certain amount of time has passed.

    When your ready to end the event just add the stone of the winning team
    [add redwon
    [add bluewon
    [add whitewon
    [add blackwon


    Distro Edits
    Playermobile.cs Edits


    Around line 75 add

    Code (C#):
    1. #region ColorWars
    2.         ColorWarRed = 0x00020000,
    3.         ColorWarBlue = 0x00040000,
    4.         ColorWarWhite = 0x00080000,
    5.         ColorWarBlack = 0x00100000,
    6.         #endregion
    7.         #region Event
    8.         IsInEvent = 0x00020000,
    9.   #endregion
    Around line 331
    Find


    private

    int m_GuildMessageHue, m_AllianceMessageHue;

    Below Add
    Code (C#):
    1. #region ColorWars
    2.         [CommandProperty(AccessLevel.GameMaster)]
    3.         public bool ColorWarRed
    4.         {
    5.             get { return GetFlag(PlayerFlag.ColorWarRed); }
    6.             set { SetFlag(PlayerFlag.ColorWarRed, value); }
    7.         }
    8.  
    9.         [CommandProperty(AccessLevel.GameMaster)]
    10.         public bool ColorWarBlue
    11.         {
    12.             get { return GetFlag(PlayerFlag.ColorWarBlue); }
    13.             set { SetFlag(PlayerFlag.ColorWarBlue, value); }
    14.         }
    15.  
    16.         [CommandProperty(AccessLevel.GameMaster)]
    17.         public bool ColorWarWhite
    18.         {
    19.             get { return GetFlag(PlayerFlag.ColorWarWhite); }
    20.             set { SetFlag(PlayerFlag.ColorWarWhite, value); }
    21.         }
    22.  
    23.         [CommandProperty(AccessLevel.GameMaster)]
    24.         public bool ColorWarBlack
    25.         {
    26.             get { return GetFlag(PlayerFlag.ColorWarBlack); }
    27.             set { SetFlag(PlayerFlag.ColorWarBlack, value); }
    28.         }
    29.         #endregion
    30.         #region Event
    31.         [CommandProperty(AccessLevel.GameMaster)]
    32.         public bool IsInEvent
    33.         {
    34.             get { return GetFlag(PlayerFlag.IsInEvent); }
    35.             set { SetFlag(PlayerFlag.IsInEvent, value); }
    36.         }
    37.         #endregion
    Notoriety.cs

    around line 503

    find


    Faction srcFaction = Faction.Find(source,
    true, true);

    Faction trgFaction = Faction.Find(target,
    true, true);


    Above add


    Code (C#):
    1. #region ColorWars
    2.             if (source is PlayerMobile && ((PlayerMobile)source).ColorWarRed && target is PlayerMobile && (((PlayerMobile)target).ColorWarBlue || ((PlayerMobile)target).ColorWarWhite || ((PlayerMobile)target).ColorWarBlack))
    3.                 return Notoriety.Enemy;
    4.  
    5.             if (source is PlayerMobile && ((PlayerMobile)source).ColorWarRed && target is PlayerMobile && ((PlayerMobile)target).ColorWarRed)
    6.                 return Notoriety.Ally;
    7.  
    8.             if (source is PlayerMobile && ((PlayerMobile)source).ColorWarBlue && target is PlayerMobile && (((PlayerMobile)target).ColorWarRed || ((PlayerMobile)target).ColorWarWhite || ((PlayerMobile)target).ColorWarBlack))
    9.                 return Notoriety.Enemy;
    10.  
    11.             if (source is PlayerMobile && ((PlayerMobile)source).ColorWarBlue && target is PlayerMobile && ((PlayerMobile)target).ColorWarBlue)
    12.                 return Notoriety.Ally;
    13.  
    14.             if (source is PlayerMobile && ((PlayerMobile)source).ColorWarWhite && target is PlayerMobile && (((PlayerMobile)target).ColorWarBlue || ((PlayerMobile)target).ColorWarRed || ((PlayerMobile)target).ColorWarBlack))
    15.                 return Notoriety.Enemy;
    16.  
    17.             if (source is PlayerMobile && ((PlayerMobile)source).ColorWarWhite && target is PlayerMobile && ((PlayerMobile)target).ColorWarWhite)
    18.                 return Notoriety.Ally;
    19.  
    20.             if (source is PlayerMobile && ((PlayerMobile)source).ColorWarBlack && target is PlayerMobile && (((PlayerMobile)target).ColorWarRed || ((PlayerMobile)target).ColorWarWhite || ((PlayerMobile)target).ColorWarBlue))
    21.                 return Notoriety.Enemy;
    22.  
    23.             if (source is PlayerMobile && ((PlayerMobile)source).ColorWarBlack && target is PlayerMobile && ((PlayerMobile)target).ColorWarBlack)
    24.                 return Notoriety.Ally;
    25.  
    26.  
    27.             #endregion
    Please enjoy and let me know i will support this system as much as i can.

    *Edit*

    Here is a Video that show how to start/end event
    its only basic but give the idea



    Sorry its kinda lame never done a video tutorial before hope you enjoy

    *End Edit*
    Greed likes this.