Aller au contenu

Photo

Bomb Beasts - Just 3 Questions (for now anyway...)


  • Veuillez vous connecter pour répondre
16 réponses à ce sujet

#1
Tarot Redhand

Tarot Redhand
  • Members
  • 2 688 messages

First a quick thank you to all those that have recently helped me, the result of which has been sent to AD as addendum to the September ccc (page containing the post detailing it).

 

Now on to the questions. As you may know I am in the process of getting the Bomb Beasts (that were part of the June 2013 ccc) to work as I described them. Now one of them can only be hit by blunt weapons and another only by edged. Now I can probably figure out how to do these myself (using the OnPhysicallyAttacked event) but I figured that surely, because these are reasonably common special defences, someone has already written the code to do this. So my first 2 questions are

  1. Do you know of already existing script to make a creature only able to be hit by blunt weapons? 
  2. Do you know of already existing script to make a creature only able to be hit by edged weapons? 

The third question may be more tricky, as Bomb Beasts do not use weapons and have neither teeth or claws. There is one them however that can cause physical (bludgeoning to be exact) damage. So my final question (for now anyway) is

 

3.  Is there a way to cause damage in the way I have just described given the restrictions I have mentioned. If there is can you be quite specific as I haven't got a clue on this last one.

 

Thanks for any responses.

 

TR



#2
WhiZard

WhiZard
  • Members
  • 1 204 messages

The OnPhysicalAttack Event occurs after hit/miss has been determined and after the damage has been rolled.  So you might want either to look into NWNX or to give the creatures 100% damage immunity to the respective physical damage which you wish to ignore.

 

For question 3, I am not sure the circumstance which you are describing (does the bludgeoning damage occur on-hit, or is it a spell-like ability which can be used?).  If you do not wish them to use a physical attack at all, you can always assign them a special AI by setting the HotU variable and writing the associated script.



#3
henesua

henesua
  • Members
  • 3 878 messages

give the creatures 100% damage immunity to the respective physical damage which you wish to ignore.

 

I think that this is the best solution.



#4
Tarot Redhand

Tarot Redhand
  • Members
  • 2 688 messages

Thanks for the information guys. I just want to check something. On the damage immunity thing is this



void main()
{
    // This is the Object to apply the effect to.
    object oTarget = OBJECT_SELF;
    effect eDamageImmunity;

    // Create the effect to apply
    effect eImmunityPiercing = EffectDamageImmunityIncrease(DAMAGE_TYPE_PIERCING, 100); // comment out for only hit by edged
    effect eImmunitySlahing = EffectDamageImmunityIncrease(DAMAGE_TYPE_SLASHING, 100); // comment out for only hit by edged
    eDamageImmunity = EffectLinkEffects(eImmunityPiercing, eImmunitySlahing); // comment out for only hit by edged

    // remove next comment for only hit by edged
    //effect eDamageImmunity = EffectDamageImmunityIncrease(DAMAGE_TYPE_BLUDGEONING, 100);


    // Apply the effect to the object
    ApplyEffectToObject(DURATION_TYPE_PERMANENT, eDamageImmunity, oTarget);
}

the sort of thing you were describing, to be placed in the OnSpawn event of the creatures involved? The above code has not yet been tested. Is there anything I should be aware of regarding it?

 

TR



#5
Tarot Redhand

Tarot Redhand
  • Members
  • 2 688 messages

@ WhiZard regarding question 3. It is physical damage that is applied at the time that the Bomb Beast makes a successful attack. This damage is applied to the creature/PC being attacked. I hope that clears that up.

 

TR



#6
WhiZard

WhiZard
  • Members
  • 1 204 messages

Thanks for the information guys. I just want to check something. On the damage immunity thing is this the sort of thing you were describing, to be placed in the OnSpawn event of the creatures involved?

 

TR

 

You can just assign the properties to the skin via the Toolset.



#7
WhiZard

WhiZard
  • Members
  • 1 204 messages

@ WhiZard regarding question 3. It is physical damage that is applied at the time that the Bomb Beast makes a successful attack. This damage is applied to the creature/PC being attacked. I hope that clears that up.

 

TR

 

My question was whether you wished to make this as a standard attack, or a spell-like ability, or just a scripted occurrence within the special AI?  For standard attacks you can give creatures claw, bite, gore, or slam items to specify the attack damage type and amount.  These items will not be seen in-game and cannot be disarmed (they represent natural attacks).



#8
Tarot Redhand

Tarot Redhand
  • Members
  • 2 688 messages

@ WhiZard Thanks for that. Finally found those invisible items even though it is somewhat counter intuitive to go into the creatures inventory.

 

On the damage immunity thing, I wouldn't be writing a script if I could find where to do it in the creatures blueprint. Perhaps I am getting ready for the optician again. So if you could just point me in the right direction, I would really appreciate it. Thanks.

 

TR



#9
WhiZard

WhiZard
  • Members
  • 1 204 messages

Go into the module and open an area.

 

Under Wizard select "Item Wizard."

 

Select the "Creature Item" type for skins or  "Creature Bludgeon Weapon" for the slam (bludgeoning creature weapon).

 

Name the item and select which palette subtype it belongs to, and then look for it under the custom palette.  Add item properties.

 

View your creature, and open its inventory.  Switch to the natural equipment tab.   Locate your skin/weapon to right under the custom palette.  Click and drag these items onto the natural equipment slots.  Save the creature.



#10
Tarot Redhand

Tarot Redhand
  • Members
  • 2 688 messages

Thanks. Found them, made them, included them.

 

TR



#11
Tarot Redhand

Tarot Redhand
  • Members
  • 2 688 messages

I have a new problem I'm afraid. I have a custom wav file. I can make (and have made) a fully working sound object (i.e. with blueprint) using it. However when I try to use playsound("my custom wav"), I do not hear it. The playsound() is used as part of a pseudo heartbeat that is used in one of the events of the bomb beasts (it is just a brief "click" sound).

 

I have another sound issue that may relate to the first. Currently I have the soundset of the creatures blank. I have also made sure, in the onspawn event code, that there are no footstep sounds. The trouble is that the bomb beasts make the same sound as an air elemental and incidentally did so even before I made those two changes. Just in case there was some setting in it, I have looked through the model, but to no avail. Is there some setting in the creatures blueprint, that I am too blind to see, that will get rid of this sound?

 

Any ideas for me to try?

 

Thanks in advance.

 

TR



#12
henesua

henesua
  • Members
  • 3 878 messages

Sounds:

the ambient sounds that a creature makes are established by the appearance.2da file. I forget the column's name, but there is one for sounds. And this correlates to a row in another 2da… appearancessnd.2da or some such thing. I forget the exact name. Its fun to play with though, once you find it.

 

playing a sound via script on a creature or PC requires that the action queue be freed up. So you have a few options here. You can clearallactions before playing the sound or you can spawn an object near the bomb beast, wait a moment or so, then have that spawned object play the sound.



#13
Tarot Redhand

Tarot Redhand
  • Members
  • 2 688 messages

Thanks. I have got rid of the ambient sound having looked in both 2da's. I found one that was silent across the board then changed the entry in appearance.2da. On the other sound. ClearAllActions was only partially successful, so I have tried simply assigning the playsound to the PC which works much better. Still not perfect as the sound only plays when the PC is not in combat. I'm tempted to leave it at that though as spawning an invisible object looks as though it might really complicate matters when there are multiple Bomb Beasts, all attacking at once. Mind you it's not the spawning that would be the major problem, it's the clean up afterwards.

 

TR


  • henesua aime ceci

#14
Tarot Redhand

Tarot Redhand
  • Members
  • 2 688 messages

Just a quick one this time. Is there a way to prevent a monster from dropping any treasure when it dies? I already have an OnDeath script that does an important job so having no OnDeath script is not an option.

 

Thanks in advance.

 

TR



#15
WhiZard

WhiZard
  • Members
  • 1 204 messages

Random treasure is typically generated in the monster's OnSpawn script.



#16
Tarot Redhand

Tarot Redhand
  • Members
  • 2 688 messages

Thanks. Found it. Eliminated it. Works great in the cutomised version of x2 random walk routine I am using.

 

TR



#17
Tarot Redhand

Tarot Redhand
  • Members
  • 2 688 messages

At the time of posting I am now almost halfway through (15 out of 35 done = 60 blueprints out of 140) getting the Bomb beasts working properly. Now onto my new question.

 

Does anyone know if somebody has made the following spells in script form?

  • pyrotechnics
  • fire seeds
  • dancing lights
  • hypnotic gaze (actually not sure this is a spell, could be a creature ability)

By that I mean I really want the effects of these spells but don't need such things as radial menus etc. I know that a couple of these are in the PRC but untangling them from that would be a daunting task especially as they went to the trouble doing the whole radial menu bit.

 

Thanks in advance.

 

TR