I need help with some monster decorate coding.
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
- lizardcommando
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California
I need help with some monster decorate coding.
I just finished making the sprites for a Mech enemy and now I need help with the coding.
How do I have it so that when it dies, it spawns an explosion in front of it? Also, how do I have it so that after it plays its death animation, the mech explodes? What I mean is how do I have it so that after the death animation plays, it turns into an explosion object?
How do I have it so that when it dies, it spawns an explosion in front of it? Also, how do I have it so that after it plays its death animation, the mech explodes? What I mean is how do I have it so that after the death animation plays, it turns into an explosion object?
- lizardcommando
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California
Will the A_SpawnItemEx command work on the current version of ZDoom or is it only for the SVN build of ZDoom and GZDoom only? I'm using the current version of ZDoom only.
BTW, I followed HotWax's advice with the A_Explode thing and it doesn't look that bad. The problem is that it won't make an explosion sound. Do I just add in an extra frame with the A_PlaySound command? Also, I have a question about Melee attacks. How come it'll play the enemy's shooting sound for the melee attack?
BTW, I followed HotWax's advice with the A_Explode thing and it doesn't look that bad. The problem is that it won't make an explosion sound. Do I just add in an extra frame with the A_PlaySound command? Also, I have a question about Melee attacks. How come it'll play the enemy's shooting sound for the melee attack?
- lizardcommando
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California
- Unknown_Assassin
- Posts: 2468
- Joined: Wed Apr 12, 2006 5:17 pm
- Location: Where dead carcasses lie
- Contact:
Add a frame of A_PlaySound. Since you had already define the attack sound for the monster, you will have to use this function to play a different sound.lizardcommando wrote:I got that A_PlaySound thing fixed for the explosion, now the problem I'm having is that every time the mech hits me with its melee attack, it'll make the gunshot sound from its long range attack. How do I fix this.
- lizardcommando
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California
- lizardcommando
- Posts: 1489
- Joined: Thu Sep 07, 2006 12:24 pm
- Location: Boringland, California