Developer's blog 4: Halloween

Developer’s blog: Halloween

On the 28th of October 2008, the Hallowe'en event and the Swept Away quest were introduced as part of the Hallowe'en Event and Quest update.

To celebrate this year's Halloween, a diverse range of spooky content has been reintroduced following last year's successful event. In this development blog, we will examine the processes behind both this year's and last year's updates, exploring the steps necessary to bring nostalgia to a whole new level.


Custom quest: Witches' Chronicles

The standout addition for this year is our very first fully-fledged custom quest. Building on the foundation laid by the ExtendedNPCs feature in 2022, we embarked on an exploration of a system that could accommodate more than just 'fake NPCs'. Both the Easter and Pride events of this year featured one quest each, serving as 'secret' prototypes for these custom quests. This experiment allowed us to gain valuable insights into the requirements of an enhanced Quest API.

You might wonder how all of this is achievable. Ultimately, it comes down to what the server instructs the client to do. Consequently, the client possesses the capability to perform actions typically associated with in-game activities. However, it's important to note that the underlying logic for these actions is typically handled server-side. With all of that in mind, even we were surprised what we were capable of doing!

The quest reintroduces us to the beloved witches Maggie, Lottie, and Wendy, well-remembered from the 2008 Halloween event and Swept Away quest. The trio has made a triumphant return! After a hiatus of 15 years, they've managed to break free from a temporal prison and are eager to uncover the mysteries of the past. Notably, Lottie has joined forces with Professor Oddenstein at Draynor Manor, where they are diligently working on an experiment that holds the promise of revealing the long-awaited answers.

This quest presents distinctive puzzles that challenges players in various ways. Additionally, Draynor Village faces a looming threat that must be thwarted, culminating in an epic boss battle that alludes to the resurgence of a particular mystery figure, that may well see a return in the real game.

Witches' Chronicles quest starting area, roughly in the same spot as it was in 2008

Unique features

  • Interaction pathing

  • Custom chat dialogs with a variety of chat-head emotions, including non-players

  • Challenging puzzles with mechanics

  • Simulated combat, including hit-splats and health/energy bars

  • Progress-saving (excluding puzzles), much like a real quest

  • Restored sounds and atmospheric effects

  • MusicAPI: allowing for music overrides, even if the server plays another track

  • ConditionAPI: able to check for conditions such as whether you are wearing certain items, or calculate the relative distance between Actors (NPCs and Players)

  • ActionAPI: allowing the players and NPCs to perform a variety of animations, graphics, projectiles, over-head text and more

  • MessageAPI: allowing game messages to be sent in various forms

  • Custom NPCs, models, graphics and particle emitters

Environmental changes

Last year's area overhauls have made a comeback, covering most of Misthalin, including Lumbridge, Varrock, Draynor, Port Sarim, and Rimmington. Despite the absence of new overhauls, we hope you'll enjoy the return of these dramatic atmospheric effects for Halloween. We took the 2008 Trick or Treat! as our foundation for this special project. Leveraging the available assets, we performed significant overhauls on various zones. Since we don't have access to the original maps and possess greater capabilities than Jagex had back then, we decided to take it a step further by incorporating an immersive environment.

A comparison of the Halloween area overhaul in Lumbridge

A bunting problem

Surprisingly, one of the bigger challenges was to restore the buntings (the flags that have spooky props hanging from them). This is because the objects consist of multiple models, that then have to line up. This issue in particular is meant to show how something small can quickly become a difficult problem. Don't worry if this becomes overwhelming, it is merely to show you one of the challenges that can arise whilst restoring.

We wanted something that allows us to place the entire structure at once with a specific rotation. Because these buntings have many different models and sizes, we had to create an algorithm that did all of this for us. The algorithm had to do the following:

  • Place the (floor 1) bunting with a specific size.

  • Place the lower supporting models (floor 0). The distance between them depends on the size of the bunting.

  • Add a tileflag to the tiles above it to make it show even when roofs are hidden.

  • Set custom height on floor 1 to align the supports with the bunting

  • Normalize floor 0 heights

    • Because the height of a tile is not determined in the middle, but rather in the bottom right, all the tiles in x+1 and y+1 are also affected.

  • All the tile coordinates in the steps above have to be calculated in a manner in which it lines up with the rotation of the bunting; as well as the bunting having a special object property that doesn't allow it to rotate 360 degrees, but rather only rotates in a 90- and 180-degree angle (270 and 360 flipping the object).

All of this allows us to create a function that places buntings for us. We then still have to carefully pick spots in which to place them. Because the height normalization affects the first floor, we have to be careful not to use it too closely to roofs, or else they would sink or float. The image below visualizes all the things combined.

image

Eek

One of the noteworthy features is Eek the Spider! Thanks to some engine adjustments, we've successfully restored the original spider's functionality. Old School's Eek now also offers an option to perform its classic animation!


Random events restore 2022

Last year, some of the random events were restored as part of the H'ween update. This gives us the perfect opportunity to delve into some of the challenges with this restore, and why it had been put off for a while.

The primary challenge lies in accessing the designated area. As we lack direct access, we employ a workaround by transferring the entire random event map's data into a location where we have control. In this particular instance, we opted for the Lumbridge Swamp as our destination. From this point onward, we can initiate the restoration process.

image
Visualization of the restored gravedigger event getting copied into the lumbridge swamp, with the yellow zone depicting the random event region.

You might have noticed that the map includes multiple random events. Just like how Jagex uses templates for Player-Owned Houses, they have a similar method for copying bits of the map to different locations. It's worth mentioning that not all random events use this trick, but the ones you see here certainly do.


That's it for this blog! Enjoy the event, and the quest!

— Leyline, and the rest of the HDOS team

Some special mentions in relation to the quest, thank you all!

  • Brainfree: Massive help as always, testing, ideas and engine work! It could not have been possible without you

  • Zoinkwiz: Providing a base API for dialogues (QuestHelper)

  • Rebellious: Initial play-testing when various parts of the quest were absurdly difficult

  • Superman: Initial play-testing

  • RS Orchestra: Restoring music tracks

  • Kris: Providing several IDs that were difficult to find

  • EXDosis: Additional play-testing and announcement banner

  • Zukitwo: Play-testing

  • J3: Play-testing

  • Haavard: Play-testing

  • Jacob: Play-testing