JazzJackrabbit Community Forums

JazzJackrabbit Community Forums (http://www.jazz2online.com/jcf/index.php)
-   JCS & Scripting (http://www.jazz2online.com/jcf/forumdisplay.php?f=5)
-   -   Jazz1Enemies.asc (http://www.jazz2online.com/jcf/showthread.php?t=20063)

Violet CLM Jan 27, 2017 09:26 PM

Jazz1Enemies.asc
 
Download link

This is an in-progress angelscript library, for use in single player levels, which will allow you to place any enemy from JJ1 in your levels as a fully functional enemy with just a single line of code. For instance, the following script replaces the JJ2 Diamondus enemies with the JJ1 Diamondus enemies, but you could replace any other event instead, e.g. replacing green springs with Marbelara dragons or whatever suits the need of your level design.
Code:

#include "Jazz1Enemies v05.asc"

void onLevelLoad() {
        Jazz1::MakeEnemy(OBJECT::NORMTURTLE, Jazz1::Enemies::Diamondus_TurtleGoon);
        Jazz1::MakeEnemy(OBJECT::BUMBEE, Jazz1::Enemies::Diamondus_BumblingBee);
}

JJ1 enemies are generally a lot simpler than JJ2 ones, of course, but there are a lot of them, and adding a few non-standard enemies (with little to no scripting skills required of you) is a good way to make your SP level stand out from the crowd.

These are not intended to be pixel-perfect recreations of the original enemy code (unlike in PlusOJ). Generally behaviors have been rewritten to move more smoothly, e.g. an enemy that previously moved four pixels every other tick will now move two pixels every tick. This is generally a good thing but I felt obliged to mention it.

This library is still in development, though, and currently includes only the enemies from JJ1's first six episodes and HH94. The enemies introduced by JJ1 CD (episodes A-C) and HH95 are not yet implemented.

proud2beamerican Jan 28, 2017 06:01 AM

This is really awesome!

Tubelec blaster doesn't look right though. Originally it has the yellow lights flashing (those 3 little pixels). Also could you remind me how to rotate those hazards? So the blaster can be placed on walls and ceilings, not just on the floor.

Violet CLM Jan 28, 2017 09:45 AM

Quote:

Originally Posted by proud2beamerican (Post 491054)
Originally it has the yellow lights flashing (those 3 little pixels).

Ah, I forgot about that detail, thanks. It's easy to miss palette swap animations like that because they're not explicitly marked in the JJ1 sprites, and then they have to be recreated manually in the .j2a.
Quote:

Also could you remind me how to rotate those hazards? So the blaster can be placed on walls and ceilings, not just on the floor.
The instructions spell out how to put them on the ceiling. There is no precedent for them being on the walls, however.

proud2beamerican Jan 28, 2017 11:52 AM

Quote:

Originally Posted by Violet CLM (Post 491055)
Ah, I forgot about that detail, thanks. It's easy to miss palette swap animations like that because they're not explicitly marked in the JJ1 sprites, and then they have to be recreated manually in the .j2a.

I actually did that long time ago for my tileset:
[IMG]http://i.imgur.com/7U3t5W8.png[/IMG]

Not sure if the palette is 100% right though.

Quote:

Originally Posted by Violet CLM (Post 491055)
The instructions spell out how to put them on the ceiling. There is no precedent for them being on the walls, however.

Right, I see that. But still putting them on the walls seems extremely important to me. Do you think that would be possible in the next update?

Violet CLM Jan 28, 2017 11:04 PM

Hmmm. I'm trying not to go too far afield from the JJ1 originals besides making movement less jerky, but the tubelectric blasters are so unique as it is that I don't think putting them on walls would be letting myself in to make many other such changes. That's reasonable.

Jelly Jam Jan 29, 2017 02:33 PM

I tried out the basic code you put on this thread. This is cool! Please keep this up! I like many of the JJ1 enemies.

Also, is there a list of the JJ1 enemies' names of some sort?

Violet CLM Jan 29, 2017 02:59 PM

Quote:

Originally Posted by Jelly Jam (Post 491063)
Also, is there a list of the JJ1 enemies' names of some sort?

HELPME.EXE comes with JJ1 and gives names and descriptions of all the enemies from episodes 1-6. If anything similarly official exists for the other episodes I don't know about it. :(

Jelly Jam Jan 29, 2017 03:21 PM

Aw, cuz IIRC those airboard turtles with guns are from episode A
Thanks anyway :)

Love & Thunder Jan 30, 2017 06:23 AM

I think there's a manual for the CD version which lists some info about enemies from episodes A-C, but I don't think all copies of it had that manual.

Jelly Jam Jan 30, 2017 08:10 AM

Ah, well I actually meant names such as Diamondus_TurtleGoon, so i can load the enemies. I don't even know how to load the JJ1 sparks.

Violet CLM Jan 30, 2017 10:41 AM

Quote:

Originally Posted by Violet CLM (Post 491052)
instructions (found at the top of the .asc document)

Instructions include optional methods for slightly changing how the enemies behave, and also (if you scroll down just a bit) the full list of included enemy names.

Jelly Jam Jan 30, 2017 10:56 AM

Oh, looks like I missed it. Thanks again.

Violet CLM Feb 18, 2017 02:30 PM

Download link

Updated to version 0.2. Changes:

  • Renamed Tubelectric_Blaster to Tubelectric_BlasterVertical and added Tubelectric_BlasterHorizontal.

  • Added all enemies from Episode 2 (Letni, Technoir, and Orbitus).

  • Added a bool parameter (defaults false) to the Jazz1::MakeEnemy function to draw that enemy using my TrueColor library. That way you can have enemies use (roughly) their original JJ1 colors instead of edited ones to fit into JJ2's standard sprite palette. You have to package the .bmp file/s with your script then, but there are detailed reminders for this in the new "Packaging Instructions" section of the giant instructions comment.

Violet CLM Dec 10, 2017 11:17 PM

Download link

Updated to version 0.3. Changes:

  • Added all enemies from Nippius and Holidaius.

  • Updated the included TrueColor.asc to the latest release.

  • Added a version number to the filenames, in case of future behavior changes.


PT32 Dec 12, 2017 07:58 AM

Just wanted to say this sounds like a really awesome project

AvalancheMaster Jan 6, 2018 06:20 AM

Thank you so much, the effort that goes into this really pays off!

Several questions/suggestions:

* Do you plan to implement the sounds as well? As it stands, at least some of the enemies are completely silent.

* Do you plan to implement boss battles?

* Would you consider including an option for enemy sprites that are more similar to JJ2's style, (if an artist is willing to contribute some minimal effort to the project, that is) mainly fixing some horrible shading (no major edits), or you want to keep this as close to JJ1 as possible?

Violet CLM Jan 6, 2018 10:30 AM

Quote:

Originally Posted by AvalancheMaster (Post 492340)
* Do you plan to implement the sounds as well? As it stands, at least some of the enemies are completely silent.

I have little to no technical knowledge about sound or sound files. I don't know how to extract samples from JJ1, and I don't know how to translate JJ1's sound settings into JJ2's sound settings. Someone else would have to do all the heavy lifting on this one. In the meantime, there are SetDeathSound, SetBulletFireSound, and SetBulletExplosionSound options already in the library, though you have to provide your own samples for those or use JJ2's native ones.
Quote:

* Do you plan to implement boss battles?
Not particularly. JJ1 boss behaviors are just complicated enough that they'd take some work to plausibly recreate, yet not complicated enough that they'd be interesting experiences in JJ2. And I think it's more useful to have a source of additional enemies.
Quote:

* Would you consider including an option for enemy sprites that are more similar to JJ2's style, (if an artist is willing to contribute some minimal effort to the project, that is) mainly fixing some horrible shading (no major edits), or you want to keep this as close to JJ1 as possible?
The idea as stated doesn't excite me, and sounds like mission creep, but I guess I might change my mind if someone actually tried this.

Violet CLM Feb 8, 2018 11:31 PM

The latest version has been uploaded to J2O. Changes:
  • The latest versions of TrueColor and Resize are fully integrated, so the color quality is better than it was before and you can resize any enemy to any size while setting it up, still as a single API call.
  • Fixed glitch of SetWalkingEnemyCliffReaction method not working for any enemy at all.
  • Added SetEnemySpeedsAreScalable, SetBulletSpeedsAreScalable, and GetFirstFrame methods.
  • Probably fixed some edge case issue with trying to use the same enemy (with different eventIDs) twice, once with useTrueColor enabled and once without.
(No new enemies have been added, though, so we're still on v03 for the .j2a file.)

Violet CLM Jun 11, 2019 07:16 PM

The latest version has been uploaded to J2O. Changes:
  • Added all enemies from episodes 3-6, making there be fifty-seven enemies in all (plus two minor horizontal variants as discussed above).
  • Updated TrueColor and Resize again, meaning the images are now all .png files instead of .bmp, and resizing can involve antialiased edges.
  • Added SetPointsFormula method.
  • Small bug fixes to flying snake enemies (e.g. Orbitus_SilverSnake) and to certain resized enemies using the SetEnemySpeedsAreScalable method.
  • Fix to TrueColor version of Holidaius_HandHorizontal


Fun fact that doesn't affect you in any way: almost all the enemies use shared behavior classes with no more specification than a few numbers and their animation structures. Only the following enemies require actual method overrides:
  • Letni_BugCeiling (unique walking-on-ceiling behavior)
  • Scraparap_GunnerDrone (unique death animation)
  • Scraparap_LaunchCart (you can stand on it without being hurt)
  • Turtemple_JeTurtle (unique floating-on-water behavior)
  • Dreempipes_TerrapinSwimmer (sleeps above water)
  • Pezrox_ClammyVertical (unique moving-up-and-down behavior)
  • Crysilis_GoldenBounceSpike (animation implemented in code instead of .j2a)
  • Battleships_Generator (doesn't hurt and is drawn to the foreground)

chandie Jan 28, 2020 01:23 AM

Wow amazing library. Are you still up to add A,B,C and HH95 enemies?


All times are GMT -8. The time now is 03:57 AM.

Powered by vBulletin® Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
JCF © 2001-Infinity Jazz2Online