The blog post "Standard Patterns in Choice-Based Games (2015)" by Emily Short explores common design patterns employed in interactive narratives, specifically those using a choice-based structure where the player progresses the story by selecting from presented options. Short argues that understanding these recurring structures can be beneficial for both authors creating these games and players engaging with them. Recognizing these patterns allows authors to deliberately utilize established techniques, potentially streamlining the development process and creating a more consistent player experience. For players, awareness of these patterns can enhance their understanding of the underlying mechanics driving the narrative, allowing for more strategic engagement with the choices presented.
The post identifies several key patterns, categorizing them for clarity. One prominent category revolves around gating, where access to content or specific outcomes is controlled by earlier choices, often involving acquiring items, skills, or relationships. These gates can function as prerequisites, locking off content until specific criteria are met, or as branching paths, diverting the narrative based on the player's accumulated state. This pattern can enhance replayability by incentivizing players to explore different paths on subsequent playthroughs to unlock previously inaccessible content.
Another significant category encompasses timers and counters. This refers to the implementation of hidden or explicit tracking mechanisms that influence the narrative's progression. A timer might represent a deadline the player must meet, while a counter could track the accumulation of resources or the development of a relationship. These mechanisms introduce a sense of urgency or consequence to player choices, as inaction or specific actions can increment or decrement these values, impacting future events. The post highlights how these mechanics can create a dynamic and evolving narrative landscape, even within the constraints of a choice-based system.
Short also discusses patterns related to character relationships and internal states. These patterns often involve tracking the player character's relationship with non-player characters (NPCs), influencing the availability of certain dialogue options, actions, or even entire plotlines. The internal state of the player character, including traits like personality, morality, or mental health, can also be tracked and influence the unfolding narrative in similar ways. This allows for a more personalized player experience, reflecting the consequences of choices on the player character's development and relationships.
The post further delves into hub and spoke structures, where the narrative revolves around a central location or concept (the hub) from which various self-contained storylines (the spokes) branch out. This allows players to explore different facets of the narrative world at their own pace, returning to the central hub to select new avenues for exploration. This structure offers flexibility in narrative design and can accommodate varying lengths and complexities of individual storylines.
Finally, Short touches upon the concept of nested patterns, where multiple patterns are combined or layered to create more intricate and nuanced narrative experiences. For example, a gated section of the narrative might itself contain timers and counters, adding complexity to the player's decision-making process. This demonstrates the potential for sophisticated and dynamic storytelling even within the seemingly simple framework of choice-based games.
By highlighting these patterns, the blog post provides a valuable framework for understanding the underlying design principles of choice-based games, fostering both greater appreciation for existing games and offering guidance for aspiring creators. It emphasizes that despite the apparent simplicity of choosing between predetermined options, the strategic deployment of these patterns can result in rich, engaging, and replayable interactive narratives.
This GitHub repository, titled "pseudo3d," showcases a remarkably concise implementation of a raycasting engine written entirely in Bash script. The provided code leverages the shell's built-in string manipulation capabilities and arithmetic functionalities to render a pseudo-3D perspective of a simple world map defined within the script itself. The world map is represented as a two-dimensional array of characters, where different characters signify different types of walls or empty space.
The core of the raycasting algorithm involves iterating through the screen's horizontal pixels, calculating the viewing angle for each pixel based on the player's position and viewing direction. For each pixel, a "ray" is cast from the player's position into the world map, effectively tracing a line until it intersects with a wall character. The distance to the wall intersection is then calculated using a simplified distance formula.
This distance value determines the height of the wall segment to be drawn on the screen for that particular pixel. Closer walls result in taller wall segments, creating the illusion of perspective. The rendering process utilizes ANSI escape codes to directly manipulate the terminal output, drawing vertical lines of varying heights representing the walls. Different wall characters in the map are visually distinguished by using different colors for the rendered wall segments, again achieved through ANSI escape codes. The rendering process updates the terminal output in real-time, providing a dynamic view as the player navigates the world.
The player's movement and rotation are handled through basic keyboard input. The script detects specific key presses, updating the player's position and viewing angle accordingly. This dynamic update combined with the real-time rendering loop creates an interactive experience where the player can explore the defined world from a first-person perspective. While rudimentary, the implementation successfully demonstrates the fundamental principles of raycasting in a surprisingly minimal and accessible manner using the Bash scripting environment. The code's brevity and reliance on built-in shell functionalities serve as a testament to the versatility and unexpected capabilities of the Bash scripting language beyond typical system administration tasks.
The Hacker News post titled "A Raycaster in Bash" (https://news.ycombinator.com/item?id=42475703) has generated several comments discussing the project, its performance, and potential applications.
Several commenters express fascination with the project, praising the author's ingenuity and ability to implement a raycaster in a language like Bash, which isn't typically used for such computationally intensive tasks. They admire the technical achievement and the demonstration of what's possible even with limited tools.
Performance is a recurring theme. Commenters acknowledge that the Bash implementation is slow, with some sharing their own experiences and benchmarks. Suggestions are made for potential optimizations, including using a different shell like zsh
for potential performance gains, leveraging awk
, and exploring alternative algorithms. The inherent limitations of Bash for this type of application are recognized, and the discussion explores the trade-offs between performance and the novelty of the implementation.
The practical applications of the project are also debated. While some view it primarily as a technical demonstration or a fun experiment, others suggest potential use cases where performance isn't critical. One commenter proposes using it for generating simple visualizations in constrained environments where other tools might not be available.
The choice of Bash itself is discussed. Some commenters question the rationale behind using Bash, suggesting more suitable languages for such a project. Others defend the choice, highlighting the value of exploring unconventional approaches and pushing the boundaries of what's possible with a familiar scripting language. The discussion touches upon the educational aspects of the project and its potential to inspire creative solutions.
Beyond the technical aspects, there's appreciation for the author's clear and well-documented code. The readability and organization of the project are commended, making it easier for others to understand and learn from the implementation. The project is also seen as a testament to the flexibility and power of Bash, even beyond its typical use cases. Some commenters express interest in exploring the code further and potentially contributing to its development.
Boardgame.io presents itself as a comprehensive open-source JavaScript framework specifically designed to streamline the development of turn-based multiplayer games. It offers a robust and structured approach to managing game logic, state transitions, and player interactions, abstracting away many of the complexities inherent in building online multiplayer experiences.
The library's core functionality revolves around a declarative approach to defining game rules and mechanics. Developers describe the game's flow using a clearly defined state object, along with functions that dictate how that state changes in response to player actions or game events. This allows for a clean separation of concerns, making the game logic easier to reason about, test, and maintain.
Boardgame.io handles the intricacies of turn management, ensuring that players act in the correct sequence and according to the defined rules. It provides mechanisms for defining different phases within a turn, allowing for complex gameplay structures. Furthermore, it supports asynchronous gameplay, enabling players to take their turns at their own pace without blocking the progress of others.
Networking is a core aspect of Boardgame.io, providing built-in support for connecting multiple players. While it doesn't mandate a specific networking solution, it offers integration with various transport layers, granting developers flexibility in choosing the best fit for their project's requirements. This allows for both local and online multiplayer experiences.
Beyond core game logic, Boardgame.io also offers a rich set of features to enhance the development process. It includes a debugging user interface that allows developers to inspect the game state, step through turns, and simulate player actions, significantly simplifying the debugging and testing process. It also provides tools for logging game events, facilitating analysis and replay functionality.
Furthermore, Boardgame.io strives to be platform-agnostic. While it is written in JavaScript, it can be integrated with various front-end frameworks and libraries, allowing developers to choose their preferred technologies for rendering the game interface. It also offers support for server-side rendering, enabling complex game logic to be executed securely on the server.
In essence, Boardgame.io aims to be a comprehensive solution for developing turn-based multiplayer games, encompassing everything from game logic and state management to networking and debugging tools. Its declarative approach, combined with its robust feature set, makes it a valuable tool for both novice and experienced game developers alike, empowering them to create engaging and sophisticated online game experiences with relative ease.
The Hacker News post discussing Boardgame.io, a JavaScript engine for turn-based games, has generated several comments exploring its utility, comparing it to similar tools, and discussing its potential applications.
Several commenters praised Boardgame.io for its simplicity and ease of use, especially for prototyping game mechanics. One user mentioned using it for a quick prototype and finding it "surprisingly easy" to get a game running. Another appreciated its focus on the game logic, freeing developers from dealing with lower-level networking and state management. The ability to easily add bots and debug games was also highlighted as valuable features.
The discussion also touched on Boardgame.io's suitability for different types of games. While it's clearly well-suited for turn-based games, some commenters questioned its applicability for more complex games or games requiring real-time interaction. One user pointed out the potential limitations for games with a high degree of animation or graphical complexity.
Comparisons were made to other game development frameworks and libraries. Phaser was mentioned as a more robust solution for graphically rich games, while Colyseus was suggested as a good option for real-time multiplayer games. The consensus seemed to be that Boardgame.io occupies a specific niche for turn-based games with simpler graphical requirements, where its ease of use and focus on game logic are particularly advantageous.
Some commenters shared their personal experiences using Boardgame.io for specific projects. One user mentioned creating a card game prototype, while another discussed its potential for educational game development. These examples illustrated the practical applications of the framework and its versatility.
A few commenters also raised questions or offered suggestions for improvement. One user inquired about the possibility of integrating Boardgame.io with existing front-end frameworks like React or Vue.js. Another suggested exploring WebAssembly for performance improvements.
Overall, the comments section paints a picture of Boardgame.io as a valuable tool for developing turn-based games in JavaScript, particularly for prototyping and for projects where simplicity and ease of use are prioritized over graphical richness or real-time interaction. While it may not be suitable for every game development scenario, its focused feature set and approachable API make it a compelling option for its target audience.
This GitHub repository, titled "Elite - Source Code (Commodore 64)," meticulously presents the original source code for the seminal video game Elite, specifically the version developed for the Commodore 64 home computer. It is not simply a dump of the original code; rather, it represents a painstaking effort to make the code understandable to modern programmers and those interested in the history of game development. Mark Moxon, the repository's author, has undertaken the extensive task of annotating the 6502 assembly language code with detailed comments and explanations. This documentation clarifies the function of individual code sections, algorithms employed, and the overall structure of the game's logic.
The repository includes not just the core game code, but also the associated data files necessary for Elite to run on a Commodore 64. This comprehensive approach allows for a complete reconstruction of the original development environment. Beyond the raw source code, the repository provides a wealth of supplementary material. This includes documentation regarding the game's intricate algorithms, such as those governing procedural generation of the game world, 3D graphics rendering on limited hardware, and the underlying physics engine. Furthermore, the repository likely incorporates explanations of the various data structures employed within the game, shedding light on how information like ship specifications, trade commodities, and planetary data were stored and manipulated.
The stated goal of this project is to provide a deep dive into the technical ingenuity behind Elite, making its inner workings accessible to a broader audience. By providing clear annotations and supplementary documentation, the repository aims to serve as both an educational resource for aspiring programmers and a historical archive preserving a landmark achievement in video game development. This detailed reconstruction of the original Elite source code provides valuable insights into the constraints and challenges faced by developers working with the limited resources of 8-bit home computers in the 1980s and showcases the innovative solutions they devised to create such a groundbreaking and influential game.
The Hacker News post titled "Documented and annotated source code for Elite on the Commodore 64" generated a fair number of comments, primarily expressing appreciation for the effort involved in documenting and annotating this classic piece of gaming history.
Several commenters reminisced about their experiences with Elite on the Commodore 64, sharing personal anecdotes about the impact the game had on them. Some discussed the technical challenges of developing for the C64, especially with its limited resources, praising the ingenuity of the original programmers. The clever use of 6502 assembly language tricks and mathematical optimizations were frequently mentioned and analyzed.
A few comments delved into specific aspects of the code, such as the use of fixed-point arithmetic, the generation of the game world, and the rendering of the wireframe graphics. These technical discussions highlighted the elegant solutions implemented within the constraints of the C64's hardware.
The meticulous documentation and annotation work by Mark Moxon was highly praised. Commenters emphasized the value of this effort for preserving gaming history and for educational purposes, allowing aspiring programmers to learn from classic code examples. The accessibility of the annotated code was also appreciated, making it easier to understand the intricacies of the game's inner workings.
Some comments linked to related resources, including other versions of Elite's source code and articles discussing the game's development. Others expressed interest in exploring the code further and potentially contributing to the documentation effort.
A particularly compelling comment thread discussed the difficulties of reverse engineering old code, especially without original documentation. The work involved in deciphering the original programmers' intentions and adding meaningful annotations was recognized as a significant undertaking.
Overall, the comments reflected a strong sense of nostalgia and respect for the technical achievements of the original Elite developers. The appreciation for the detailed documentation and annotation work underscores the importance of preserving and understanding classic software for future generations.
Summary of Comments ( 53 )
https://news.ycombinator.com/item?id=42678647
HN users discuss various aspects of choice-based games, focusing on the tension between player agency and authorial intent. Some highlight the "illusion of choice," where options ultimately lead to similar outcomes, frustrating players seeking meaningful impact. Others argue for embracing this, suggesting that the emotional journey, not branching narratives, is key. The implementation of choice is debated, with some advocating for simple, clear options, while others find value in complex systems with hidden consequences, even if they add development complexity. The importance of replayability is also raised, with the suggestion that games should offer new perspectives and outcomes on subsequent playthroughs. Finally, the use of randomness and procedural generation is discussed as a way to enhance variety and replayability, but with the caveat that it must be carefully balanced to avoid feeling arbitrary.
The Hacker News post titled "Standard patterns in choice-based games (2015)" has generated a moderate number of comments, delving into various aspects of choice-based game design. While not an overwhelming discussion, several commenters offer interesting perspectives.
One compelling thread revolves around the tension between player agency and pre-authored narrative. A commenter argues that choice-based games often create an illusion of choice, where pre-determined outcomes are simply dressed up with different wording. They suggest that true player agency requires more dynamic systems, where choices have meaningful and lasting consequences that ripple through the narrative. This sparks a small debate, with others arguing that the enjoyment of choice-based games lies precisely in experiencing carefully crafted narratives, and that excessive player agency can lead to incoherent or unsatisfying stories. The discussion touches upon the inherent limitations of the format, and the different expectations players might bring to these types of games.
Another commenter highlights the importance of pacing and information control in choice-based games. They argue that effective games carefully reveal information to the player, creating suspense and a sense of discovery. Choices should feel meaningful not just in their immediate consequences, but also in how they shape the player's understanding of the game world and its underlying mysteries. This comment connects to the earlier discussion about player agency, suggesting that a sense of agency can be achieved through strategic information management, even within a pre-authored narrative.
A few commenters also discuss specific examples of choice-based games, both successful and unsuccessful, illustrating the points raised in the broader discussion. These examples range from classic text adventures to more modern visual novels, highlighting the evolution of the genre and the different design approaches employed.
While the discussion isn't exceptionally lengthy, it offers some insightful perspectives on the challenges and opportunities of choice-based game design, touching upon issues of narrative structure, player agency, and information control. The comments generally agree on the importance of carefully crafted narratives, while differing on the degree of player agency that is desirable or even achievable within the format.