[Update] Hocus Pocus Level editor v1.2

Discuss classic and favorite computer or console games here.
Hisymak
Vortininja
Posts: 46
Joined: Sat Mar 26, 2016 20:13

[Update] Hocus Pocus Level editor v1.2

Post by Hisymak » Sat Mar 26, 2016 21:33

[Update] New version (1.2) was released. Go to the new post about the update.

Hello Keeners! Do you remember Hocus Pocus, a classic platforming game made by Apogee/Moonlite Software in 1994? If yes, then I have awesome news for you: A fully functional level editor for this game is finally here!

I was looking for an editor for this game for a long time. I tried out Camoto Studio (which seems to be a promising tool for editing many classic DOS games), but it was incomplete and not capable of editing all features of the game. I also ran into an editor called Hocus Creation Station, but it was quite hard to use and I don't think it could edit everything too.
So finally I decided to make my own editor, which would be easy to use and complete in terms of level editing. And after almost two months of work the editor is finally here!
Of course I want to thank Modding Wiki and all its members for reverse-engineering the Hocus Pocus map format and publishing all the information I needed to make the editor.
And very special thanks go to ravage for making Hocus Pocus Doom, an amazing Total Conversion which makes the good old Hocus Pocus into 3D. I really liked this project, which showed me that Hocus Pocus is still a popular game with potential and gave me inspiration for making this editor.

Download:
Here

Installation:
Just unzip all files into your Hocus Pocus game folder.
You can set up paths (your game and Dosbox folder) and several other settings in HocusEditor.ini file - it will be created after opening and closing the program first time.
Please note that only Hocus Pocus v1.1 Full and 1.0 demo versions are supported. However it is possible to configure it for any other version, all what is needed is to provide offsets of level/graphics data inside HOCUS.DAT file.

Feature list:
- Open/save maps directly from/to HOCUS.DAT file or an external map file
- Advanced map editing possibilities, allowing you make maps more easily and fast:
- Three editing modes: Basic Tile mode, Pattern mode and Block mode
- Predefined Pattern and Block presets for each tileset, ability to add your own presets
- Undo&Redo feature
- Copy&Paste feature (works also between different maps)
- Fill area feature
- Auto-place window edges feature
- Shift map feature
- Full support for editing all special objects and events (teleports, monsters, switches, locks...)
- Support for editing animation and monster data
- Show/hide specific map layers, show grid feature
- Minimap feature (providing schematic overview of all map)
- Save map image feature
- Simple statistics (number of crystals, healing potions, points etc. in a map)
- Test map feature (map is saved, game is launched in Dosbox, tested level is "saved" on the first savegame slot)
- Many keyboard shortcuts, pattern/block presets can be quickly selected with keys (1,2,3,4,5,...,Q,W,E,R,T,...)

NOTE: The controls of the editor may seem to be a bit complicated - there are many different actions for different mouse buttons (left, right, middle) and their combinations with Shift and Ctrl keys. I strongly recommend reading the help section in the program and getting familiar with the controls, so that you will be able to use full potential of editing possibilities and make your maps easily and fast.

Missing stuff:
- There is no manual/guide available yet as I am quite lazy and suck in doing this. If you know well this game then after playing a bit around with the editor you will definitely figure it out. You can always ask me for help here or via PM/email if anything is not clear to you. Please do it, as this helps me to understand most unclear/confusing things about the editor and make it better. The editor was not tested by anyone except me.
- The editor cannot change the level time limit (time you must beat to get extra point bonus) because it is stored inside HOCUS.EXE. For now you can hex-edit it (the information is available here) and I will possibly add it in the new update of the editor.
- The way of distributing new levels/mods is not fully clear. The editor can export level into a separate file which can be then opened and saved into HOCUS.DAT with the editor, or some patch on HOCUS.DAT can be used.
- Configuration files for all available game versions

Screenshots:
Image
Image[/url]
Last edited by Hisymak on Sun Nov 13, 2016 0:23, edited 2 times in total.

User avatar
lemm
Blorb
Posts: 682
Joined: Fri Jul 03, 2009 10:18
Location: canada lol

Post by lemm » Sun Mar 27, 2016 2:28

Neat.

Now Hocus Pocus can finally have some good levels made for it :dopefish

User avatar
troublesomekeen
Vorticon Elite
Posts: 1145
Joined: Fri Feb 03, 2012 8:01
Location: Three-Tooth Lake
Contact:

Post by troublesomekeen » Sun Mar 27, 2016 3:19

Oh my gollygoshesgaloshes. Thanks for posting this here!
Imma try this out...
Image
Commander Keen in... Canteloupe Quest!

User avatar
Levellass
S-Triazine
Posts: 5261
Joined: Tue Sep 23, 2008 6:40

Post by Levellass » Sun Mar 27, 2016 9:37

*Slow clap*

This is impressive. I remember doing this (Well not exactly this of course) when getting annoyed at Modkeen. This is very impressive indeed. I applaud your achievement.
What you really need, not what you think you ought to want.

User avatar
Roobar
Vorticon Elite
Posts: 2793
Joined: Tue Jan 08, 2008 16:12

Post by Roobar » Sun Mar 27, 2016 9:45

People are still using windows XP? Wow... :eek

Anyway, I'm definitely trying this. Good work on it and thanks for sharing!

Violet CLM
Grunt
Posts: 23
Joined: Sun Nov 04, 2007 10:14

Re: [Release] Hocus Pocus Level editor

Post by Violet CLM » Mon Mar 28, 2016 3:50

Oh boy oh boy!
Hisymak wrote:I also ran into an editor called Hocus Creation Station, but it was quite hard to use and I don't think it could edit everything too.
That was mine! Or rather, I started (but didn't finish) two or three separate HP level editors*, and I know one of them was called that but I don't remember which one anymore. Oh well. Anyway I'm really excited to see that someone finally finished the job... that minimap in the screenshots looks really cool!

I have an unfinished HP level from like ten years ago... maybe this is the incentive I needed to get back to it? Gosh! This is so cool!
Image


*I also made the terrible HP x-mas mod, and this abandoned fangame (only the second and fifth episodes are playable)... ah, good times


EDIT: Here's a question (haven't downloaded yet): Did you figure out elevators? I remember back in the day I thought I had all the files (other than the sprites) figured out but I could never find anything that seemed to specify which tiles functioned as elevators. Satisfy my decade-old curiosity? :begging

Hisymak
Vortininja
Posts: 46
Joined: Sat Mar 26, 2016 20:13

Re: [Release] Hocus Pocus Level editor

Post by Hisymak » Mon Mar 28, 2016 18:43

Violet CLM wrote:Oh boy oh boy!
Hisymak wrote:I also ran into an editor called Hocus Creation Station, but it was quite hard to use and I don't think it could edit everything too.
That was mine! Or rather, I started (but didn't finish) two or three separate HP level editors*, and I know one of them was called that but I don't remember which one anymore. Oh well. Anyway I'm really excited to see that someone finally finished the job... that minimap in the screenshots looks really cool!
Hello Violet CLM! It's really exciting to meet people who have attempted to make their Hocus Pocus editor. I must say making the editor was really fun for me, so I wonder why nobody have fully completed one in so many years. I think your Hocus Creation Station was the most-complete one among those I tried.
And yeah minimap. I see it's not much common in platformer game editors, but it is definitely a must-have thing!
Violet CLM wrote:I have an unfinished HP level from like ten years ago... maybe this is the incentive I needed to get back to it? Gosh! This is so cool!
Well I saw a screenshot from your custom map which was posted in some forum. That's probably the only existing custom Hocus Pocus map in the world, as I haven't made any real map with my editor because I suck at mapping.
But that your map looks really awesome!!! I would really like to have and play it even if it is unfinished! I'm so much looking forward to see some custom levels for Hocus Pocus, since the originals are quite boring and have childish difficulty.
I will also try how the editor can handle maps with a custom tileset, but I guess there will be a problem because the offsets and sizes of files inside HOCUS.DAT are stored in editor's configuration (it does not read HOCUS.EXE for this), so I will most likely need to add it.
Violet CLM wrote:EDIT: Here's a question (haven't downloaded yet): Did you figure out elevators? I remember back in the day I thought I had all the files (other than the sprites) figured out but I could never find anything that seemed to specify which tiles functioned as elevators. Satisfy my decade-old curiosity? :begging
Nope, I haven't figured out elevators, sorry...

Violet CLM
Grunt
Posts: 23
Joined: Sun Nov 04, 2007 10:14

Re: [Release] Hocus Pocus Level editor

Post by Violet CLM » Mon Mar 28, 2016 23:46

Hisymak wrote:I must say making the editor was really fun for me, so I wonder why nobody have fully completed one in so many years. I think your Hocus Creation Station was the most-complete one among those I tried.
Honestly, from what I recall I just got stuck figuring out UIs for some of the specialty files, particularly switch combos and animated tiles. I vividly remember staring at the ceiling at a party a long time ago trying to figure something out, and then I never did.
I will also try how the editor can handle maps with a custom tileset, but I guess there will be a problem because the offsets and sizes of files inside HOCUS.DAT are stored in editor's configuration (it does not read HOCUS.EXE for this), so I will most likely need to add it.
Actually, every time I edited a tileset I made sure to make its filesize exactly the same as the original version's, so that won't be an issue. :) Looking through my Hocus folder suggests I actually assembled two other sets besides the one in that screenshot... gosh. But I should probably finish my Hocus Pocus La-Mulana mod first if anything.

EDIT AGAIN: Did I ever post this here? Tool to replace Hocus's music files

Hisymak
Vortininja
Posts: 46
Joined: Sat Mar 26, 2016 20:13

Post by Hisymak » Wed Mar 30, 2016 9:41

I tried your abandoned fangame, it's actually a reimplementation of Hocus Pocus, looks awesome and interesting. However it's easy to die by getting out of the map. And I like how you used the unused Hocus items, what does umbrella exactly do?
Again I'd like to ask whether it is possible to send me that your new level/mod for Hocus Pocus or just anything you made for Hocus Pocus? Or you want to finish your mod first? :p
And any experience with HocusEditor so far?

User avatar
K1n9_Duk3
Vorticon Elite
Posts: 472
Joined: Mon Aug 25, 2008 9:30
Location: Germany
Contact:

Re: [Release] Hocus Pocus Level editor

Post by K1n9_Duk3 » Fri Apr 01, 2016 18:22

Violet CLM wrote:Did you figure out elevators? I remember back in the day I thought I had all the files (other than the sprites) figured out but I could never find anything that seemed to specify which tiles functioned as elevators. Satisfy my decade-old curiosity? :begging
The elevators are stored as tile number (left tile an right tile) in the executable. Each level has its own entry in that table (i.e. the elevator tiles are stored per level, not per tileset, much like the tile attribute files). Levels that don't have any elevators have both values (left and right) set to -1.

How do I know all of this? Because I have seen source code for Hocus Pocus somewhere.
Hail to the K1n9, baby!
http://k1n9duk3.shikadi.net

User avatar
Levellass
S-Triazine
Posts: 5261
Joined: Tue Sep 23, 2008 6:40

Post by Levellass » Sun Apr 03, 2016 1:46

Well I'll be darned! That solves a mystery.
What you really need, not what you think you ought to want.

User avatar
Roobar
Vorticon Elite
Posts: 2793
Joined: Tue Jan 08, 2008 16:12

Post by Roobar » Sun Apr 03, 2016 7:49

Even if I have set the path to Dosbox and the game in HocusEditor.ini, when I try to test it, it still says that it cannot find Dosbox. :confused

Violet CLM
Grunt
Posts: 23
Joined: Sun Nov 04, 2007 10:14

Post by Violet CLM » Mon Apr 04, 2016 1:42

Hisymak wrote:And I like how you used the unused Hocus items, what does umbrella exactly do?
Nothing IIRC. It was supposed to be a shield, but none of the enemies got enough code to attack you with, so there was nothing for it to do.

Anyway, it occurred to me that I actually had an entire custom level layout sitting around from 2003, just waiting to be converted into data that Hocus Pocus can actually read. So that seemed like a good way of testing this new editor! All told, this took somewhere around four hours to recreate:
Image
Download here (replaces E1L1). The par time is unchanged due to data location issues, but I'd suggest maybe pretending it's 450, or 375 if you're serious.

Hisymak
Vortininja
Posts: 46
Joined: Sat Mar 26, 2016 20:13

Post by Hisymak » Mon Apr 04, 2016 17:51

wiivn wrote:Even if I have set the path to Dosbox and the game in HocusEditor.ini, when I try to test it, it still says that it cannot find Dosbox. :confused
Hmmm. This is what I have in my HocusEditor.ini, it works pretty well:
DosboxPath=D:\DOSBox-0.72\DOSBox\dosbox.exe
Probably you don't have the dosbox.exe filename included. If it still won't work then I'll need to investigate.
Violet CLM wrote:Anyway, it occurred to me that I actually had an entire custom level layout sitting around from 2003, just waiting to be converted into data that Hocus Pocus can actually read. So that seemed like a good way of testing this new editor! All told, this took somewhere around four hours to recreate:
Download here (replaces E1L1). The par time is unchanged due to data location issues, but I'd suggest maybe pretending it's 450, or 375 if you're serious.
Oh my... Thank you! Finally some decent custom level to play.
It was quite challenging and secrets were not so easy-to-get, I beat it on first try on normal, took me 1322 seconds.
The only thing that was a little annoying was that some treasure (goblets) were hard to get (you always jump over them) and I often fell to lava.

User avatar
Lunick
Vortininja
Posts: 267
Joined: Tue Jun 01, 2010 10:37
Location: Melbourne, Australia
Contact:

Re: [Release] Hocus Pocus Level editor

Post by Lunick » Wed Apr 06, 2016 1:44

K1n9_Duk3 wrote: How do I know all of this? Because I have seen source code for Hocus Pocus somewhere.
That's funny, I don't recall the source code for Hocus Pocus ever releasing, where did you see it "somewhere"?
Lunick is Here

Post Reply