sprites by sebabdukeboss20, code by Dan Gaskill
thanks to JBlade for extracting and arranging sprites
Download:
https://www.dropbox....BOSSES.zip?dl=0
Instructions: Dump all included files into a virgin vanilla Duke 3D folder with the most recent version of EDuke32 in it. The included EDUKE.CON will load the code for the new boss. All the code for it is actually in the PIGBOSS.CON file, and you are free to copy it and modify it into whatever project you want. Obviously, you need to pay attention to things like the path in the sound definitions and the CON load order if you move shit around. The code is mostly standalone, but it does use state standard_jibs, so it has to load after that. This boss supports standard Duke 3D features such as being freezable, shrinkable, and respawning on DIG difficulty. EDIT: minor update, now works properly with expander
The PIGBOSS is tile 5120. Pal 0 is big and tough, other pal variants are smaller and less tough. I did not make it end the game when you kill it, since in most cases that is not desirable (a trivial addition if anyone wanted that though). Tile 5121 will make it stayput in a sector. It will work that way but it is is not optimized for that.
I will update this post later with more notes. In the meantime, a caution: While I will fix reported bugs, I can verify that the boss works with the most recent Eduke32. Since this is intended for creators to use in their projects, it is assumed you have a basic knowledge of how to put something in the game. I will not be sympathetic to people posting about how they can't get it to work if they are not following directions and seem to have no knowledge of how the game works, and I may even delete such posts.
______________________________________________________
Some Notes on the Pigcop Boss
This is a relatively barebones version because it is made to be compatible with vanilla Duke 3D or ported to other projects. Extra bells and whistles may not be desirable in a given project, or they may require putting code in various places (such as the player, the hud or other enemies) that would complicate porting the enemy. One obvious example would be giving the pigcop boss a shout that buffed nearby pigcops and/or had a status effect on the player. Another example would be giving the boss some pathfinding AI. On the cosmetic side, it would be nice to have some effects sprites (e.g. for when he hits the ground) -- but the project it is ported to might already have good sprites or systems in place for stuff like that. One feature I did want to include, though, but ended up leaving out was having it fire a modified mortar from one of its barrels. The reason I didn't is, no matter what offset I put on the projectile definition, I could not get the projectile to spawn on the correct side of the boss sprite, despite following the directions in the wiki on PROJ_OFFSET. I know a hackish way around this, but it was too hackish for this project.
From a gameplay coding standpoint, what makes the pigcop boss interesting is that the sprites have not only a firing animation, but also melee, roar, taunt and stomp. I ended up not using the stomp, but if it were added I would recommend putting it in as a random variation on the taunt. If you are coding an enemy you have to think about the enemy in terms of both presentation and gameplay. If an enemy looks amazing with varied animations, but the player is able to cheese it and kill it without the enemy being able to do much, then all that work on animations is wasted. Likewise, if you code an attack for the enemy, but the player is never going to be in a situation where the enemy would use it, then it was a waste of effort. In the case of the pigcop boss, this presents something of a problem because: (1) taunt and roar animations make the boss helpless, possibly giving the player quick kill opportunities, and (2) the player will generally try to avoid getting near the boss on general principle, making it unlikely that the melee can be used. My solutions were (1) give the boss damage resistance during the taunt and roar animations, and (2) make the boss sprint towards the player and use the melee offensively. Then it was just a question of balancing the elements properly, so the boss still threatens with a normal gun attack, and taunts/roars enough but not too much. The knockback effect on the melee is based on a force push that I coded for Duke Forces. It makes the attack seem powerful, but also it moves the player away to allow for a reset so the boss doesn't spam melee.