Main Page | Recent changes | Edit this page | Page history

Printable version | Disclaimers | Privacy policy

Not logged in
Log in | Help
 

Eliminate Shrunk Enemies Attacking Bug

From EDukeWiki

A screenshot of the “Shrunk Enemies Attacking” bug.
A screenshot of the “Shrunk Enemies Attacking” bug.

You probably have seen this bug before.

If you shoot an shrunken enemy, and it activates the hitting animation, it will start processing the normal enemy code, but still remain small and not go back to the original size.

To fix that bug, you need to find the main ifhitweapon statement in the enemy code, which is in GAME.con by default. You will find that code many times, but probably all them will be already in the if condition from the main ifhitweapon or you have confused ifhitweapon with ifwasweapon.

All you have to do to fix this bug is add an ifai AI<enemyname><SHRUNK\SHRINK> break statement before the main ifhitweapon. Remember to search at the beginning of the enemy code for name of their shrunk artificial intellegence, as the Assault Trooper's (actor LIZTROOP) is AITROOPSHRUNK while the Pig Cop's (actor PIGCOP) is AIPIGSHRINK.

Sample:
In the Assault Trooper's (actor LIZTROOP) code, there will be the state state checktroophit where there are many ifhitweapon primitives, but they are all before ifhitweapon state checktroophit, so all them are already under that main tag.

Here is the actual code described above:

  ifhitweapon
    state checktroophit

Change it to this:

  ifai AITROOPSHRUNK
    break
  ifhitweapon
    state checktroophit

Do you remember what happens when you shoot an Assault Captain before he teleports? Only when he come back he will fall dead / explode on jibs / etc. With this code this is exactly what will happen with the shrunken enemy, only when he grow back he will hit the shoots taken when shrunken. That will too fix another way to the bug happens: At Damn I'm Good skill, Shoot with bullets weapons an shrunken enemy and kill him. If he respawn, will be an shrunken attacking enemy.

It may take a bit of work, but in the end, you will receive the fruits of your labor. Image:Wink.gif

Retrieved from "http://localhost../../../e/l/i/Eliminate_Shrunk_Enemies_Attacking_Bug_a2e7.html"

This page has been accessed 51 times. This page was last modified 17:45, 17 November 2006 by EDukeWiki user Hendricks 266. Based on work by Tails *ORIGINAL*.


[Main Page]
Main Page
Recent changes
Random page
EDuke32.com

Edit this page
Discuss this page
Page history
What links here
Related changes

Special pages
Bug reports