Ranged Enemies Throw Their Weapons At You

Discuss modding questions and implementation details.
User avatar
Magicono43
Posts: 1141
Joined: Tue Nov 06, 2018 7:06 am

Re: Ranged Enemies Throw Their Weapons At You

Post by Magicono43 »

So I was able to use the diseaseplayer werewolf command on a level 3 character, and it worked after a few days, so maybe lvl 1s do have some disease immunity? Anyway, I did some testing. I used the Transform self spell and believe I became a werewolf, nothing visually changed, but I did get a large stat boost, so I assume it worked?

With this I let some humanoid enemies attack me and they were all able to land hits on me, which is strange, because I think that werewolves are supposed to be immune to anything that is below silver? All of these enemies only had steel and iron on the corpses. Also of note, since I was not immune to their attacks, they did not change the skillID they were using to attack me with, so I don't believe they changed to using unarmed, but I guess that makes sense since I was not immune to their attacks at any point it seems.

Maybe player lycanthropy has not been fully implemented or something, since I thought the player became immune to lesser materials after becoming one.

User avatar
BadLuckBurt
Posts: 948
Joined: Sun Nov 05, 2017 8:30 pm

Re: Ranged Enemies Throw Their Weapons At You

Post by BadLuckBurt »

Magicono43 wrote: Fri Mar 06, 2020 7:23 pm I was thinking there was something like that, never really thought Privateer's Hold would pull some punches like that. Might even be some protection for level 1 characters since I left the hold and got infected by an actual wereboar, but still not seeing any changes. Will now have to try on a higher level character and see if it works.
Fresh out as in, just starting out. It doesn't have anything to do with the PH dungeon itself. You should have no problem infecting a higher level character.

I never play as werewolf or boar but I think you normally only change at a full moon or when you need to 'feed' so try fast traveling for a bit. It is fully implemented and you are immune to lesser weapons in werewolf form. Perhaps you should just play the game for a bit before trying to test things.
DFU on UESP: https://en.uesp.net/w/index.php?title=T ... fall_Unity
DFU Nexus Mods: https://www.nexusmods.com/daggerfallunity
My github repositories with mostly DFU related stuff: https://github.com/BadLuckBurt

.

User avatar
Magicono43
Posts: 1141
Joined: Tue Nov 06, 2018 7:06 am

Re: Ranged Enemies Throw Their Weapons At You

Post by Magicono43 »

BadLuckBurt wrote: Fri Mar 06, 2020 7:44 pm
Magicono43 wrote: Fri Mar 06, 2020 7:23 pm I was thinking there was something like that, never really thought Privateer's Hold would pull some punches like that. Might even be some protection for level 1 characters since I left the hold and got infected by an actual wereboar, but still not seeing any changes. Will now have to try on a higher level character and see if it works.
Fresh out as in, just starting out. It doesn't have anything to do with the PH dungeon itself. You should have no problem infecting a higher level character.

I never play as werewolf or boar but I think you normally only change at a full moon or when you need to 'feed' so try fast traveling for a bit. It is fully implemented and you are immune to lesser weapons in werewolf form. Perhaps you should just play the game for a bit before trying to test things.
Just tried again and realized that I messed up. Was able to transform into the werewolf form, and I was immune to the human enemies attacks, the ones that had lesser weapons at least. HOWEVER, the big thing from this is that the ones that I was immune to did NOT change to using something that would be effective, such as their hands. So that code you linked before could actually be non-functional, if i'm understanding it correctly.


EnemyAttack.cs:

Code: Select all

void MeleeDamage()
        {
            if (entityBehaviour)
            {
                EnemyEntity entity = entityBehaviour.Entity as EnemyEntity;
                EnemyEntity targetEntity = null;

                if (senses.Target != null && senses.Target != GameManager.Instance.PlayerEntityBehaviour)
                    targetEntity = senses.Target.Entity as EnemyEntity;

                // Switch to hand-to-hand if enemy is immune to weapon
                Items.DaggerfallUnityItem weapon = entity.ItemEquipTable.GetItem(Items.EquipSlots.RightHand);
                if (weapon != null && targetEntity != null && targetEntity.MobileEnemy.MinMetalToHit > (Items.WeaponMaterialTypes)weapon.NativeMaterialValue)
                    weapon = null;

                damage = 0;
That code does not seem to function, at least not when I just tested it.

Post Reply