hitmissile doesnt do damage

Post here about all aspects of D2 mod making whether it's information, problems or whatever. Please specify whether your post is relating to Classic D2 or the Expansion.

Moderator: Nizari

Post Reply
kulasdq
Posts: 16
Joined: Tue May 04, 2021 6:04 pm
United States of America

hitmissile doesnt do damage

Post by kulasdq » Fri Jul 02, 2021 4:29 am

Its me again. Im having trouble with hitmissile this time. I tried to make my thunderstorm blast into a nova when it hits the enemy. Per the missile function guide, I used the frozen orb's hit function (pclthitfunc and psrvhitfunc) and added to thunderstorm. I added hitsubmissile 1 and clthitsubmissile1. I copied the nova missile to the bottom, renamed it to my hitsubmissile. I changed the "skill" column to thunder storm so it can read damage from thunder storm in the skills.txt.
Tested in the game, animation looks fine, but the nova does no damage. I tried to delete "skill" then added the damage to the hitmissile, still no damage. Tried different nova, like frozenorb nova, no damage. Tried to add the parameters of the frozenorb to the thunder storm (even though i dont think it has anything to do with the hit, but I still did), no damage.
So yeh, I dont know what to do again. The guide doesnt say anything other than the hit function and hitmissile. But i guess some other fields in the txt must be changed to make it work.

User avatar
Cypress
Junior Member
Paladin
Posts: 188
Joined: Fri Dec 01, 2017 2:08 am

Re: hitmissile doesnt do damage

Post by Cypress » Fri Jul 02, 2021 3:18 pm

From my brief testing, it seems that Thunderstorm will not produce hitsubmissiles from the first missile regardless of the missile settings. However, you can make the dofunc produce a submissile which itself can produce hitsubmissiles.
Last edited by Cypress on Sat Jul 03, 2021 1:27 pm, edited 1 time in total.

kulasdq
Posts: 16
Joined: Tue May 04, 2021 6:04 pm
United States of America

Re: hitmissile doesnt do damage

Post by kulasdq » Sat Jul 03, 2021 7:57 am

Tried this on some other missiles simple as magic arrow, still do no damage. I dont know if creating a submissile on thunderstorm would work :-|

User avatar
Cypress
Junior Member
Paladin
Posts: 188
Joined: Fri Dec 01, 2017 2:08 am

Re: hitmissile doesnt do damage

Post by Cypress » Sat Jul 03, 2021 1:50 pm

A few corrections to what I said:
(1) You can use hitsubmissile.
(2) I found what may be the exception rather than a general rule because I always start with one of my favorite missiles (moltenboulderemerge) which just so happened to work well.

What you will want to do is:
(1) Clone moltenboulderemerge: copy and paste in thunderstorm1's settings from Vel to AnimSpeed, set trans=1; this will make it look like a Thunder Storm Bolt
(2) Clone frozenorb: change velocity to 0 and range to 1
(3) Give moltenboulderemergeclone hitsubmissile=frozenorbclone
(4) Set Thunder Storm's srv&cltmissilea=moltenboulderemergeclone
(5) Set frozenorbclone's hitsubmissile1/clthitsubmissile1 to whatever is desired (i.e. nova) and change s.Hitpar1 and cHitpar1 to increase/decrease the number of missiles (set to 1 if you want 64 missiles like most novas)

The result is that Thunder Storm will produce moltenboulderemergeclone, which will produce frozenorbclone, which will produce your nova missiles.

Also, it is important to note that moltenboulderemerge has poor settings in vanilla. I'm assuming Overworked moltenboulderemerge, which has collidekill=1. If you are not using Overworked, then be sure to set collidekill=1 for moltenboulderemergeclone.

kulasdq
Posts: 16
Joined: Tue May 04, 2021 6:04 pm
United States of America

Re: hitmissile doesnt do damage

Post by kulasdq » Sun Jul 04, 2021 12:04 am

thanks. it works!
i did notice one thing. if i removed the submissile of frozenorb, then it wont create hitmissile either. so instead of deleting it, just need to hide it.
Last edited by kulasdq on Sun Jul 04, 2021 8:31 am, edited 1 time in total.

kulasdq
Posts: 16
Joined: Tue May 04, 2021 6:04 pm
United States of America

Re: hitmissile doesnt do damage

Post by kulasdq » Sun Jul 04, 2021 12:09 am

btw, basically we can conclude that we cant just add 30/29 to a missile hit function, even though it visually blasts a nova when the main missile hits :cool: guess the guide writer didnt test in details

User avatar
Cypress
Junior Member
Paladin
Posts: 188
Joined: Fri Dec 01, 2017 2:08 am

Re: hitmissile doesnt do damage

Post by Cypress » Sun Jul 04, 2021 1:32 pm

You can add 30/29 to a missile hit function for almost all cases, srvmissilea of Thunder Storm is a very unusual instance that should not be taken as the norm. You can also change the dofunc to 1/1 if you do not want the movement behavior of Frozen Orb.

kulasdq
Posts: 16
Joined: Tue May 04, 2021 6:04 pm
United States of America

Re: hitmissile doesnt do damage

Post by kulasdq » Wed Jul 14, 2021 6:26 am

tested 30/29 on some other missiles such as magic arrow and strafe, doesnt seem to do any dmg. Is there rule determining if the hit function works on a missile?

User avatar
Cypress
Junior Member
Paladin
Posts: 188
Joined: Fri Dec 01, 2017 2:08 am

Re: hitmissile doesnt do damage

Post by Cypress » Wed Jul 14, 2021 3:42 pm

I see what you mean now, 30/29 refuses to do direct collision damage. To get around this, you could stagger the missile release. For example:
(1) Missile1 uses 14/4, hitsubmissile1/clthitsubmissile1=missile2; set alwaysexplode=1
(2) Missile2 uses 30/29, hitsubmissile1/clthitsubmissile1=missile3; set hitpars for missile count, give it range=1 (so it explodes immediately) and set alwaysexplode=1
(3) Missile3 composes the nova

In this way, missile1 deals damage on hit and explodes into a missile2 frozenorb, which explodes into a nova of missile3. It's not that the missile isn't working, it's that 30/29 is a function which does not deal collision damage.

You could also synchronize multiple, different missile release. For example, srvmissile hits a target and deals damage, while srvmissilea releases the 30/29 nova producing missile. Both the srvmissile and srvmissilea would have the same velocity, range and collision types, such that they will contact the target at the same time. But note that srvmissilea release requires specific skill functions (i.e. srvdofunc=8, cltstfunc=19, cltdofunc=17; this is what Teeth and Multiple Shot use to release their srvmissilea).

Post Reply

Return to “General Mod Making”