Danni's blog

Danni's picture

"Creative Content System", also Glorious Trainwrecks rewrite

During a Twitter conversation about the current state of Glorious Trainwrecks, an idea suddenly dawned on me: if the site, as it is, is badly designed, and this is hurting site participation, why not just go ahead and do a rewrite?

While we could just upgrade to the latest Drupal, there are several reasons why that is a terrible idea:

- Drupal is written in PHP. PHP is a terrible language.
- Drupal has too much complexity, and this bleeds into both the user experience and site maintenance. A lot of Drupal's abstractions are aimed at trying to be useful for many different configurations, but makes managing all of them more confusing.
- Despite these abstractions, Drupal doesn't provide what we need out of the box. There's already a significant amount of hackery in this place to incorporate a list of registered games, and it took multiple attempts to get it working with events. This would have to be done all over again if we were to upgrade to a newer Drupal, and this is made harder by the fact that, again, PHP is a terrible language.

Instead, I would like to focus on creating what I'd like to call a "creative content system". This will be a CMS-like system where everyone can participate by default. While typical CMSs like Drupal allow for this, it seems like they are primarily aimed at things like organizational websites rather than open participation communities. This will be software that anyone can install on their web server, especially since SpindleyQ has always wanted something in the form of a "Glorious Trainwrecks kit" for other gamedev groups to set up and host their own Klik of the Month Klubs or whatever. However, I would also like to design this around Glorious Trainwrecks and its needs.

Additionally, when I refer to "creating content", I mean all kinds of media, including art, music, games, or whatever. Hence when I talk of functionality you'll see me refer to "creations" rather than, say, "games". I want to make something that artists working in other mediums can use, too.

For the sake of ease of use and cleanliness, I am going for a simpler design. I can always add more bells and whistles later, but this way we can start off on a clean slate. Here is what I currently have in mind:

- The main page will be the Activity Stream, even when browsing as a guest. This will be similar in function to the "Recent changes" page already on this site (for those who prefer "Recent posts", I might add a "new content only" toggle or something to that effect). Only here, it would be much richer, since it would provide image previews and a synopsis of each post inline. In fact, think of it as a combination of "Recent changes" and the Newest Games list currently in GT's sidebar, or a combination of a community hub and a social network (except not really). You will be able to filter by different types of content, or switch to an index list view for archive viewing purposes.
- All content is created in the form of a "Post". A Post may either be a "Communication" (which I need a better name for) which serves as a blog/journal post, a "Creation", or an "Event".
- A "Creation" can be media of any type that the site provides. For example, a site might choose to support both "Music" and "Game" type Creations, and the user would select which one to use. While I am not aiming for a very pluggable/customizable system for version 1.0, I would at least like to make the Creation types customizable.
- Events are displayed at the top of the main page, above the Activity Stream, to draw attention to upcoming and current Events. In the case of lots of Events, the system will select a few at random, and provide an "All Events" link to view the rest.
- Site staff can "pin" posts to the top of the Activity Stream for site announcements and the likes.
- All Posts can be assigned to one or more tags/categories. The site configuration can define one or more "categories" for each post type, which are like "official" tags that are always presented to the user during post creation.
- Users get basic profiles including username, avatar, homepage link, and a list of all of their posts.
- Users can also send private messages to one another.

Because I am aiming for a relatively simple system, there are some features that won't appear. Namely:

- There is no wiki, or at least there probably won't be a wiki in the initial version. If at all. I just think a lot of CMSs try to do everything and end up only doing a few of these things well. This project is not like that. I'm not even sure how a wiki would fit in with the user experience I have in mind.
- There are no forums. If you think about it, Communication (blog) posts are basically the same thing: a user can post something to start a topic, and assign it to a tag/category and it will show up if filtering activity by tag/category. Users can comment on it like one would reply to a forum topic. So really, I think it makes all the sense in the world to not have forums. It would just be pointless duplication.

The project itself will be a webapp written in Python. I think I should be able to handle it - I'll be using a "microframework" with extensions for things like SQLAlchemy for DB access (I kind of doubt this project will see any deployment on sites large enough to need something as scalable as a NoSQL-type DB), and OAuth (so that users can log in with Twitter).

Also, I really enjoy designing things and I think this is a pretty good design so far, but I'm worried the UX might be too radically different from what GT currently has. Also, I might have missed a thing or two. Please provide some feedback, if you can. Again, I want to base a lot of the design off of GT's needs, so it's important that I get to hear some opinions from other GTers. I do not currently have any UI mockups, but I'd like to make some soon so that I can better illustrate the design I'm going for.

One last thing: Since this is software that I don't intend to be limited exclusively to Glorious Trainwrecks, we'll have to think about other sites as well. GT has a super great community full of nice people, but not all communities are like this. Much of the design revolves around assuming good faith instead of expecting people to misbehave. I have been thinking of adding in admin-configurable limitations (such as each user only being able to host three events at a time, etc.) as well as the ability to remove EG. posting permissions from problematic users. Right now I feel like I'm trying to straddle the line between creating something aimed at super nice communities like GT vs increased adoption elsewhere in not-so-happy climates. Thoughts?

Danni's picture

Tips and Kliks #03: Important Conditions

In order to make sense of how and when conditions are true and to use them to create the behaviors you want, it's good to know some of the most important ones. You'll find these under either the "Special" or "Storyboard Controls" categories when you go to create a new condition.

Always and Never

The simplest conditions are the ones that are either simply true or false: Always is always true, and Never is always false.

Always is extremely important as you need it for actions which should happen continuously. For example, you might always want the screen to scroll with your player character, or you might have a turret that should always point at its target. If you have your own custom movement system you might also want to keep objects moving. These are just a few examples of things which you would want to "always" happen, and for which using the "Always" condition is basically a requirement.

Note that Always only makes sense if you aren't placing it in an event with other conditions. In such cases, Always is unnecessary, because actions will repeat for as long as the conditions are true anyway.

Never is essentially the opposite of Always. Since Never is always false, and an event requires all its conditions to be true before it runs the actions, you might be wondering how the heck Never would ever be useful. Its use is not in running actions, but not running actions. More specifically, you can use Never to disable events for debugging purposes.

Start of frame/Start of level

"Start of frame" is only ever true once: at the very beginning of your level. Therefore, you can use it to perform any kind of setup you need. Common uses include playing music, making certain objects invisible (if you're on something older than MMF2), creating and/or positioning objects according to a set of rules, etc.

Only one action when event loops

An event's actions will keep happening every step of your game as long as the conditions are true, but what if you don't want that to happen? You add "Only one action when event loops" to the event. This condition is only true if the event's conditions were not true in the previous step.

Let's say you are making an arcade game where the player gets an extra life after reaching 50,000 points. Your first attempt at the conditions might look like this:

However, doing this will cause the game to flood the player with a constant stream of extra lives! Not what you want. Now let's add "Only one action when event loops":

This rewards the player with an extra life just once after obtaining enough points.

I should note that if the player's score somehow falls below 50,000 again, the player will become eligible for another extra life. If this isn't what you want, use "Run this event once" instead of "Only one action when event loops".

Danni's picture

Tips and Kliks #02: Anatomy of an Event

We will start off by jumping straight into the Event Editor, as that is the heart of Klik's true power, the place where you will spend most of your time designing your game's behaviors. For these next few articles, we will cover the basics you need to know to get the most out of the Event Editor.

In order to become a Klik Ace, you need ACE: Actions, Conditions, and Events. In the Event Editor, these are the building blocks that you use to describe your object behaviors. Understanding the role of each is key to understanding the Event Editor.

Actions are simply things that you can do in your game. Some examples of actions:

- Stop
- Destroy
- Create a new object
- Change animation sequence
- Add to the player's score
- Jump to the next level/frame

Conditions are bits of criteria. Some examples of conditions:

- Start of frame/start of level
- Player pressed Fire 1
- Two objects are overlapping each other
- An object is below a certain Y coordinate
- An animation has finished

Events are units that contain a set of Actions and Conditions. If the conditions for a given event are satisfied, the actions are performed.

Pictured: An event that causes the player to fire a bullet when pressing button 1, as long as there are less than three bullets in play.

Note that conditions actually have two functions. First, a condition may either be true or false. For example, if the player is holding button 1, then the condition "Repeat while Player pressed Fire 1" would be true. If the player's score is only 1000, then the condition "Player's score is greater than 2000" would be false.

An event's actions are only run if all of its conditions are true!

Second, a condition may limit which object(s) an action is applied to. Let's say you have an event with one condition: "Player pressed Fire 1". If we give this event a "Destroy Monster" action, it will destroy every single Monster in the level when you press button 1.

What if we replace that condition with "Collision between Bullet and Monster"? We will keep the "Destroy Monster" action. This time, when the condition is true, only the Monsters that have collided with any Bullets will be destroyed.

Typically, conditions serve to eliminate possible objects. That is, you use conditions to only apply actions to certain objects, and each additional limiting condition further reduces which objects targeted by the actions. There are exceptions, of course. Take the "Pick an object at random" condition. Its first use will eliminate all objects of a given type except for one that has been chosen at random. What happens if you add multiple copies of this condition? Now the actions apply to more objects! If you have "Pick an object at random" three times in an event, three objects will be picked (assuming there are three - if there are less than three, only that many will be picked).

Feel free to play around with different conditions and actions! Next, we will be covering the use of a few specific basic but important conditions.

Danni's picture

Tips and Kliks #01: A Note on the Step-thru Editor

I will start off by saying that Tips and Kliks is mostly intended to be aimed at novice to intermediate Klikkers. Tutorials for absolute beginners are important, but this is not one of them. We do have a good beginner's tutorial on this site already - see the Learning KNP FAQ.

I'd like to take the time to mention the Step-thru Editor because it's a novel concept, and also an important one - I was using it before I even touched the Event Editor.

When you use the Step-thru Editor, your game will run until certain things happen, and then pause to bring up a dialog asking you what to do next, like this:

You'll see a row of icons. By clicking on one of these, you can select an action you want the game to take in response.

The capabilities of the Step-thru Editor are rather limited, especially when it comes to the number of conditions you can write actions for:

- An object leaves or enters the playfield on the left, right, top, or bottom edge.
- An object collides with another object.
- An object collides with the background.
- All objects of one type are destroyed.
- A player presses one of the fire buttons.
- A player loses all of their lives.
- A certain amount of time has passed (accessed by pressing the Esc key).

Additionally, if you are using Klik & Play, you may only perform actions on the object(s) that triggered the event in question, and you are limited to these four actions:

- Bounce
- Wrap around playfield
- Shoot another object
- Destroy

I don't think these limitations are necessarily a bad thing. Because only a small number of the available conditions and actions are exposed, it is much easier for new users to grasp the basics of how the program works. Of course, you can't do anything advanced with this, but that's not really the point - the Event Editor covers those bases.

Because these Tips and Kliks will mostly focus on working within the Event Editor, I would strongly suggest you tinker around with the Step-thru Editor first if you're still unfamiliar with Klik. Otherwise you won't find these articles very useful.

And have fun with Step-thru! I know I did!

(Note: The Step-thru Editor was removed since MMF2.)

Danni's picture

Tips and Kliks: Introduction

Hi, all! Now that I've finished my Secret Santa game and the new year is fast approaching, I would like to announce a new series of tutorials and articles called "Tips and Kliks". I've seen quite a few people here picking up on Klik tools lately, and I think that's great! These tools actually have a lot to offer - even Klik & Play is more powerful than it seems at first glance!

Why am I doing this series? After all I've kind of sworn off of Klik and I can write code in Lua, Java, C++! Well, before I was using any traditional programming language I used Klik for all my games (and a few "apps"). Using Klik to try out new gameplay ideas helped me gain familiarity with programming, and working around limitations by writing my own behaviors trained me to think critically. It is my hope that with this series I can help others do the same.

I plan to do a new article twice a week. I most likely won't provide game files for these articles (unless it's requested), because everyone is on different tools and sometimes things change between programs. I will provide plenty of images, however, and if you need help feel free to ask.

Scope

Focus will mainly be on the earlier Klik products (KnP/TGF1), but applicable to the later programs.

- (Re)familiarization with Klik basics (objects, built-in movements, editors, etc.)
- Basics of creating your own behaviors
- Some applications of custom behaviors, such as custom movements
- Other tips and tricks

Danni's picture

Musiccccc

One day I hope to be able to make super happy and queer music.

Danni's picture

Tips & Kliks

I really want to start a tutorial series on Klik tips and tricks that applies to a broad range of Klik products (though primarily targeting the older products). I'd like to cover concepts in bite-sized pieces to serve as an introduction to the building blocks used to create more complicated behaviors in Klik, as well as provide documentation on a number of useful tricks to give aspiring Klikkers greater control over their creations. I'd also like to provide a section on Klik backward compatibility to document behavior changes going from KNP to TGF1 (and perhaps later tools as well?) so that KNP users can make their games more forward compatible while users of newer products can fix existing KNP games to run on newer systems.

I just see a lot of people getting into Klik and creating new and interesting things but sometimes aren't sure how to do advanced things. I would like to help those people arm themselves with Klik knowledge.

Danni's picture

EffBee's Plot Inventory

Based on stuff by a bunch of people but mainly mcc and ellaguro.

Here's a good portion of the games I've made for this site in the past. Titles in bold are definitely about domination. Titles in italic are kind of a stretch, and perhaps only related to domination by extreme metaphor.

Note: A few of these are spoilers maybe, so watch out.

Mel's - Get home without dying to fall damage.
Gorillaflop - Whack a burglar.
RadiclBallX - Overpower the game.
DAIRY FARMER GAIDEN: CATTLE BATTLER PINK VERSION - Shoot popsicles at the opponent cow.
Not a Romantic Comedy - Survive your crush's diabolical maze.
Jogger Stories - Become the member of a circus.
Stupid Flyguy - Kill all the Marios.
Droid Didn't Do It - Ram into Steve Jobs' face with a remote-controlled robot.
A Proper Occasion for Ripped Sprites - Grab all coins, then eat the Mushroom.
Gorillaflop: Episode 0.555647 - Whack a burglar.
KOMMANDER OF THE WINDOWS: WINDOW MAY KOMMANDER - Solve an obtuse user interface.
Klik & Activities: Santa's Workshop - Murder Santa (alt ending: destroy the Grinch's clone machine)
Cry Engine - Cry until you crash the game (secondary objective: whack floating people)
Medieval Zoo Espionage - Knock a zoo employee out, then force-feed a cake to a giraffe.
Fucuspunctophobia - Get all your blood sucked out by a giant insect.
You Must Glitch To Beat This Game - Figure out how the hell you pass each screen.
Zone Jogger - Get popsicles and avoid police officers, esp. giant ones.
Bugsss - Take over the earth.
Pretend You're Platforming - Conform to the judge's annoying rules.
Laptop Lid Roulette - Pray that the laptop doesn't explode.
I'm Not At GDC But I Made a Game Anyway - Ummm I guess this one depends on which kind of game you make.
Jesus: The Second Coming: Hamburger Flipper - Whack a giant troll and steal all his hamburgers.
Tim Allen's Gruntmaster 6000 - Get murdered by a giant cordless drill.
Jesus: The Third Coming: COME HARDER - Murder people.
Trampolelephant - Accidentally destroy a house.
Diamond Snake Jogger - Don't fall off or let the snake eat you.
Motocross TGF - Cruise through the level until you get stuck in the terrain.
Yoshi Does Drugs - Get locked in a cage and torched by Bowser.
Vector's Computer Room Sokoban - Escape the room.
Sonic Cookies RARE PROTOTYPE BETA - Go to the right.
Sonic Teaches Finding the Computer Room - Click on the computer room.
Vector's Block Ball - Discover that you are chained to the paddle.
Vector's Unchaotix - Throw Vector at a bunch of robots.
Sonic and the Green Jogger - Survive a diabolical maze.
Extreme Digital Tennis Friends - Watch a ball bounce up and down.
Shoot One Million Rockets at One Million Enemies - What the title says.
Eat Lots of Candy - Also what the title says.
Fart Racing - Win a race by farting.
Five Golden Rings - Cope with bizarre walking styles as you find each ring.
Annoying Chirping Blue Jay: Volume 1 - ...This isn't even a game.
Polite Narwhal - Don't murder any fish or break your tusk.
Annoying Chirping Blue Jay: Volume 2 - Deliver messages to people.
Combat Princess Golf - Whack an evil doctor with a golf ball.
48h - Make games while avoiding bouncing balls.
Ponies vs. Not-Ponies: A brony and a forum admin try to out-spam each other.
Go With - Get murdered by a shady man.
Jugglers Juggling Jugglers - Juggle jugglers.
Judges Judging Judges - Make judges kill each other with their own gavels.
Hot Clavicle - Set fire to tiny people.
Mow the Ice - Mow a lawn, avoid getting murdered by the owner.
Murder Thousands of Bees With a Giant Robot Mech - What the title says.
!!!!!? - The Game That Appears Second In Alphabetical Listings - Avoid getting eaten by a question mark.
Community Chainwreck 2 and 1/2: Episode 1 - Beat a man in a race, then avoid getting murdered by him.
MySharewareSoft Dubstep Maker Vista 2015 - Watch a fake satirical ad.
Grumper - Make it to the exit warp without hitting the spikes or screen edges.
Midnight Snack - Eat a giant fruit.
Pest Control in Space - Clear out a giant wasp hive.
Pest Control 360* - Clear out a giant wasp hive.
Jazz Blocks - Use blocks to direct the ball into coins and subsequently the exit.
Honey, I Shrunk the Jogger - Guide a shrunken man through a perilous house.
The Overshoe - Destroy online communities with bowling balls.
Cliché - Try to escape a room only to be placed back inside.
Springy Sproingy - Escape the island.

Danni's picture

Adventures in Lua: Part 2 - OOP

So I read a small portion of "Programming in Lua", which starts out easy enough and then becomes more and more bullshit the further you read into it. So I started skipping chapters, and then eventually decided to look elsewhere for information on OOP in Lua.

They recommended the use of metatables and goofy complicated things just to get stuff like inheritance and encapsulation working. Not my method! Relevant code is here. Any experienced Lua programmers are welcome to berate me on how my method is "too simple" and "doesn't use metatables" and stuff like that.

Next, I shall make a basic game in Love2D with this OOP method. I already have a framework in the works.

Syndicate content