Combat Remastered

You are here:
← All Topics
Version: 2019.200 Requirements:uMMORPG3d, ToolsScript Define:None
Core Changes:YesTutorial Video:No

Description

Enhances the built in combat system giving your players the ability to use any weapon type. It adds weapon types to items so you can control how they work from there. It utilizes the original animator for ease of use instead of creating multiple animators.


Core Changes

  1. [Required] Open the following script Player.cs. See Changes...
    Locate this line:
        // equipment ///////////////////////////////////////////////////////////////
        private void OnEquipmentChanged(SyncListItemSlot.Operation op, int index, ItemSlot slot)
        {
            // update the model
            RefreshLocation(index);
    
            // addon system hooks
            Utils.InvokeMany(typeof(Player), this, "OnEquipmentChanged_"); // Fhiz Core Change
        }

    Modify to match:

        // equipment ///////////////////////////////////////////////////////////////
        private void OnEquipmentChanged(SyncListItemSlot.Operation op, int index, ItemSlot slot)
        {
    // update the model RefreshLocation(index);
    #if _FHIZCURSEDEQUIPMENT if (slot.amount > 0 && ((EquipmentItem)slot.item.data).CanUnequipClick(this, (EquipmentItem)slot.item.data)) combatRemastered.AutoRemoveEquipment(slot); #else combatRemastered.AutoRemoveEquipment(slot); #endif // addon system hooks Utils.InvokeMany(typeof(Player), this, "OnEquipmentChanged_"); // Fhiz Core Change }

Installation

  1. [Required] Add the following bools to your animator: UNARMED, SLASH1H, PIERCE1H, BLUDGEON1H, SLASH2H, PIERCE2H, BLUDGEON2H, RANGEDTHROWN, RANGEDBOW, RANGEDGUN, SHIELD, DUAL
  2. [Required] Add a new animation state for each bool created, this will be there default auto attack.
  3. [Required] For each new animation state create a transition to each with CASTING, the weapon type it is (Example: UNARMED etc…), then the skill you want used (Example: Normal Attack (Warrior) etc…)
  4. [Required] Add all items from Scripts [Add to Player] to your player prefab.
  5. [Required] Attach all default auto attack skills you want to UCE_CombatRemasted under your player prefab. Note they must be in order like this: UNARMED, SLASH1H, PIERCE1H, BLUDGEON1H, SLASH2H, PIERCE2H, BLUDGEON2H, RANGEDTHROWN, RANGEDBOW, RANGEDGUN, SHIELD, DUAL
  6. [Required] On your player prefab under default skills make sure all of the default auto attack skills you just set are in the same order there, starting from the first spot. All other skills need to be after those.
  7. [Required] Change your equipment slot Weapon to MainHand and Shield to OffHand. Make sure you mark your items accordingly.

Video


Extra

  • ATTENTION: If you’re using UMA Addon from Sehlor, you will need to put the Player.cs change in the UMA Player script. Just put the combatRemastered.AutoRemoveEquipment(slot); right above RefreshLocation(index); in there.
  • ATTENTION: You can’t have the original attack animation in the animator as it will always override the other skill animations, because it only requires casting and not a combat type.

Support the IndieMMO Team Today!

Leave a reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.