at1st

LD22

Ludum Dare 22, I’m In!

Heya all,

 

Yeah, in for this one. Finally managed to get around to doing one of these.

 

Anyways, the plan:

 

Platform: Flash (Web)

Programming Language: Actionscript 2.5 (Bit of 2.0, but of 3.0) or Actionscript 3.0 (If I can manage to completely remove references to Actionscript 2.0 in my code).

Sound: Used to have experience in Personal Composer 2.0, but I don’t have a Floppy Drive or a computer that can run it anymore, so probably going to be finding some free MIDI program on the internet to do some quick songs (I had one earlier, but can’t find it at the moment.)

Graphics: Yeah, at best, I’m going to take the HAL Kirby Origin story approach to this (That is, placeholders that hopefully will inspire the final version.).

Style of gameplay: Certainly 2-D movement, not quite ready to try and import 3-D into Flash yet. (Also, see Graphics). Aside from that…well sure, anything goes, but here’s a snippet of what I hope to do this Ludum Dare – or at least, my inspirations (Will probably inspire a tl:dr;):

 

So I’ve recently been playing a slew of RPGs, most notably Star Ocean: The Last Hope (And Star Ocean 1 too, but that has no bearing here, mostly). In SO:TLH, what really struck me was the Bonus Board mechanic in battles: how this worked was that if you defeated enemies a certain way (Say, killing multiple enemies in one hit, or with a Blindside Critical Hit move), you would get a certain type of point added to this Bonus Board, and after each match, whatever your Bonus Board had in points, it would give you certain bonuses (Such as 10% more money than you would’ve gotten normally, or 1 Skill Point more per level, or 10% EXP. These can stack, so you could get 20% more EXP with two points, for example.) to your grinding. If your main leader dies in battle or gets a critical hit, the board removes these points, less so if enough points are accumulated of a certain type, in succession.

Grinding; pretty much a cornerstone of the RPG genres out there, whether it be grinding for EXP, Money, Materials, IVs, EVs, Rare Candies (See Pokémon for the last three.), Morality Points, Pieces of Hearts (For those of you who want to argue Legend of Zelda as a RPG.) – you tell me about a RPG that doesn’t have grinding in it, and I’ll show you a liar (Hint: using a mirror.). At it’s essence, grinding happens when a player is doing an action solely to get a reward, and stops caring about the action in between not having the reward and having the reward. What Star Ocean was doing here, however, was letting you get the game to acknowledge why you were grinding, and helped motivate you to care about how you went about grinding – if you’re grinding for money for something expensive, you could play each battle specifically so that you would be getting more money than usual, and you’d want to maintain the work you did in an earlier battle.

 

So there’s that. There’s also the general idea of EXP being significantly different than any other type of source in a game – instead of having to redeem it manually by finding shopkeepers or such to get something that drains it, it automatically drains itself into it’s own little drain every time you get it, and eventually tells you “Hey! You have enough to level up! So yeah! You Level Up! Don’t want that? Too bad! You’re going up a level whether you like it or not!”. It may require you to spend stat points to finish leveling up, or it may do it for you automatically, but you can’t opt-out of leveling up after reaching a certain amount of EXP. Can you imagine if quests did that for you, where as soon as you got the last quest item for a quest (Say, it told you to get 12 health potions for someone), it would immediately just remove them from your inventory and add the reward to your inventory?

I can understand why that might not work for quest inventory items (The above quest being an obvious reason if you’re about to fight an Giant Ogre or something boss-like), but I’m thinking of doing something similar in the monetary field. And/Or in others. We’ll see.

 

tl:dr; Star Ocean’s Bonus Board, instant drains like EXP model.

 

Ludum Dare 22 – I’m all alone….There’s no one here beside me!

Okay, well, that’s the spirit of Ludum Dare Classic, but also the theme.

 

Interesting, I suppose – taking elements from an JRPG with a party combat system and putting them into a solo game. Irony, I suppose, but I think I can make this work.

 

Got my folder system setup now:

 

And thinking of doing a shadowy-style game – mostly thinking of making the enemies shadows. Or making the player a shadow in a world full of light, but I’m not fully sold on that one – don’t want to make this too Limbo-y-like.

 

Anyways, that’s my plan. Just finished setting up Flash now, so working on getting some symbols down.

 

What I do know so far as a plan:

 

Background: Pale Yellow, lighting mechanics light up yellow sections to brighter yellow, possibly four levels of brightness, actually:

 

Black: Shadow Monsters all around (If non-shadow self, else no one here, and ignore the rest of this statement), really sluggish, but really powerful, and really hard to destroy – also hard to see them. Main character in this case would be fastest he can be, weaker than anything else in here, and can be seen very clearly. May be implemented just using really slow slowdown for enemies, as that let’s the player still maintain control of their character. Light Monsters blindingly fast, really, really weak though, and very easy to spot;

 

Dark Pale Yellow: Shadow Monsters regular speed, still relatively strong, easy to see, main character is slightly less faster, doesn’t stand out as much Light characters regular speed, not quite as weak as before.

 

Light Pale Yellow/Pure White: Vice Versa, more or less.

 

Bit ugly for a light/dark theme, but I haven’t really fully decided on the character.

 

If I have monsters on both sides, perhaps making him the lone person able to trascend both areas, and he’s collecting pieces of each world to…I dunno, unite them? Kind of shaky, but if I do that, then I want to add an effect where you become part of the area’s type if you stay there too long…and have some sort of dynamic lighting with light switches or such.

 

Haven’t quite thought that too far yet, but something along those lines.

 

 

~~~~

 

On the aside, however:

 

You can always find me on Twitter during the event, I’d think.

But also, checking out Google Hangouts right now, so if you want to drop by, it should be here:

 

https://plus.google.com/u/0/110280074026222776324#110280074026222776324/posts

 

Let me know if this link doesn’t work.

MileStone Get! Or another way to put it, how to avoid Actionscript 2.0 traps and finally get to Actionscript 3.0

So…not too much at the moment done, but that’s in part because I now may (I presume, that is) the final official jump to Actionscript 3.0!

 

…Okay, this is an important point for me because I’ve been stuck in Actionscript 2.5 (Half 2.0, half 3.0) for…about four years now? I haven’t been actively working on it that entire time, in fact…not really at all last year, and well, I’m proud of this change, at least.

 

I’ve done Python and Java OOP programming fine before, but I first got programming in Actionscript 2.0. Which let you code on frames. Which I do. A lot of the time. So…transitioning to Actionscript 3 has been…not so smooth.

 

Part of the problem…okay, pretty much all of it, has been creating an ActionScript object.

 

Which I got the final working copy of my code working by going here:

 

http://www.flepstudio.org/forum/object-oriented-programming-tutorials/440-tutorial-1-my-first-3-0-class.html

Thing is, this doesn’t *quite* work for me – I wanted variables already, and functions!

 

So…aside from that tutorial, the following things to keep in mind – some of these are somewhat interesting:

 

  • First off – even if you aren’t putting your Actionscript .as files (See the tutorial above if you don’t know what I’m talking about), you still need a package wrapper around your class. Which is different than Java, where having no named package for the file let you leave it alone. Default package is just “package{” – Yeap, no name, just the bracket (Make sure you close it at the end of the file – properly).

 

  • Secondly, the constructor’s…considered a function. So for your constructor, it has to go like so:

public function LightGrid(){

        //....

}

  •  Thirdly, when doing this, and linking it from an item in the library of default Flash (Right-click object in library, go to Linkage, Make sure you select “Export for ActionScript”, and input your .as file’s name in there, and hit the checkmark to validate it), DO NOT leave versions of it on your stage – it’ll complain about them if you reference them, so it’s just better practise.

Um, yeap. About all I can think of now – though you can start viewing the source (When updated) here:

 

http://www.sfu.ca/~ajr12/LudumDare22/LudumDare/

Enjoy!

 

 

 

What a horrible night to have a curse!

I made two typos when I wrote the title of the blog, and two more when writing this – make that three -, so I’m going to call it quits for tonight.

 

Oh, but PROGRESS IS MADE.

 

Anyways, quite a lot of brooding over how to deal with different grid sections and how lights themselves work with them – got a lamp class working, which means I could experiment.

 

The general idea is that, when loading a stage or whatever (Still haven’t decided how to make it work for this weekend – probably going to be a “You’re locked in the basement during a full moon – can you survive the night?” scenario, I think – with monsters assaulting you in waves spawning from light/dark sources, or in a worse case, just trying to get out, and having to solve lighting problems, I guess), the grid of parts that make up the background are calculated (Might be generic personal setup), for what lights hit what areas, then if the lights are effected, they may affect that area’s coverage.

 

So if a light is destroyed by attacks, for example, it would make everything it affected darker, unless there was another light there.  If two lights are weakened, and they cover the same area, the light will drop in that area, but not to full darkness.

 

Right now, the game let’s you click as if you were turning on a switch, and then the light would turn the one piece of grid I have right now on. Technically, it’s getting the rendering, and not actually hitting a switch…but yeah. Basically, the light is already attached to the box, and when you click, it goes through the process of assuming something’s happen to a light, and re-does the grid (Yes, of 1 right now – full grid later) – if a light is on in that area, and isn’t broken, then it lights up that area. Right now at full blast. But yeah, that’s level design. Tweaking. Comes later. <_<

 

I believe I covered enemy spawning before, but a bit more on that (It’s relevant):

So they spawn in pure darkness or pure lightness, and then follow you out. I’m thinking this will be done in game by, every quarter of a minute, say, it choses a grid section as mentioned above. If it’s pure darkness, it’ll spawn a dark enemey, if it’s pure light, then a light enemey, but if not, won’t spawn an enemy.

 

Quick enough I think to do – so once I get the lights fixed that comes after…

 

The player character. Still have to do that. Right. Also, probably sounds – though that’ll come last.

But with regards to the player character, we kind of need him before we spawn the enemies. Probably’ll be a box for now when I get to him, and then he’ll shoot lasers (Perhaps into the narrative as his laser guy toy and the enemies are his imagination run amok? Afraid of the dark, alone? Works for me.), and some basic physics (Single button jump ala Super Mario Bros., I’m thinking.). If he shoots them, they die. And then another wave of enemies comes in.

 

If I have time, that’ll be important – I think I may be able to fit in something about if you hit enemies from behind, you’d get extra something – something that goes along with the Bonus Board idea I originally brought up way back in my first post for this Ludum Dare competition – but that also requires me to use that automatic drain, and I still don’t know what to do about that thematically. Probably be scraping these two.

 

Hope you enjoyed my epileptic blog post for the day!

 

P.S. If you’re looking for the final code so far, here’s the source:

http://www.sfu.ca/~ajr12/LudumDare22/LudumDare/Source/

RIDING ON CARS! *Not actually a gameplay element

Alright, I’ve finally got the LightGrid working out – so lights, when they are directed at certain parts of the grid, they’ll react to it – based on the level of power the light has.

I was asleep until 3. So I’m glad I finally got it working. Also…see the title.

 

So yeah. The grid is going to be layed out as background panels, probably a lot smaller than they are now so that it looks smoother, but then they need to be associated with light panels. Which is where I’ve had a problem for a while as to how to do that.

 

So what I end up doing is used two symbols inside the Lamp symbol (So it’s used by the class), and pull those bounding boxes out to use them. Or more specifically, they’re stored as MovieClips. Because MovieClips simplify everything in Flash.

 

So I’m using the MovieClip Symbol object of a specific part  [Separate from the Lamp itself] of that Lamp Symbol object that’s being used, and calling that object’s “hitTestObject” method to determine if a LightGrid object item in sight:

 

So yeah – if it is, then we link the Lamp to that LightGrid object.

 

Would’ve probably been looking around in Actionscript 2.0 code, but I was lucky enough to know that a friend of mine already did the research on the function method name: namely this post here.

http://hownottoblog.tumblr.com/post/9163148238/ludum-dare-21-day-2

Thinking about how the character has gotten me to remember this particular video @7 minutes in:

(Warning: Has Profanity in it, like a lot of it. Use headphones if you’re watching this at work, and/or children you don’t want spouting specific curses.)

http://www.youtube.com/watch?v=8FpigqfcvlM

(Also, it’s 20 minutes long, so you may not want to watch it in full now. But watch it in full at some point. And if you already did, then you wasted 20 minutes away from Ludum Dare. I wish I could say I was sorry, but this is a competition. <_< :p )

So the important part out of that video is that Megaman X is on the title screen as the cursor. Something along those lines.

 

Also, RIDING ON CARS!</random reference from video>*

*Just watch the video when you have time.

 

~~~

 

Okay, but seriously, next is sorting the lights, and storing the lights in one array, and the grid parts in another.

 

Then, ground and the player character.

 

Then Switches the player can use to relate to Lamps and LightGrids (Really, the whole reason we’re doing them more or less.).

 

Then…layout of the level, I guess. Probably just going to be one hardcoded level (Maybe per difficulty level), and like…yeah. Entrance and Exit. Figuring this stuff out then.

 

Then enemies.

 

Then combat.

 

Then EXP.

Then Bonus Board.

 

Then Sounds.

 

Then animation touchups.

 

Then Title Screen?

 

I’m probably missing something, but that sounds like a reasonable setup, I think.

Well, I’m flat out of ideas…

Okay, no, that’s not true, but I can’t re-use “What a terrible night to have a curse”.

First off, let’s get the good news out of the way: I forgot to upload this last time, so here’s my current upload and the link (And yeah, I know the structure isn’t all that descriptive, I’ll get to that in a second.)

http://www.sfu.ca/~ajr12/LudumDare22/Milestone/LudumDare/

 

Second, this is really a milestone for the project, as I’ve got lights linked up now.

 

Biggest problem at the moment is that my generation takes more than 15 seconds to run. So…yeah. It crashes Flash general and a message comes up saying that it ran over the .

 

It’ll run in the browser though, so…success? I dunno – still trying to figure out how to make it bypass the general timeout – apparently using the function that I thought would work didn’t…so I’ll have to see.

 

Probably too small pieces of LightGrid created, and that’s slowing it down, but you can see what I’ve done so far.

 

Sorry this post is under 200 words. I’ll try better next time.

Recruiting L’Joe to fight off Shadow and Light alike!

Yeah, at this point, I think I have the narrative down.

 

Meet L’Joe:

L'Joe here is the hero of our game, here to be the last defence against the evil shadow monsters and the traitorous light monsters. Or something.

L’Joe here has been locked in his basement by his parents (They weren’t really aware of this at the time – busy, you know, preparing.) as they went and caught their plane to Hawaii for a vactation.
Therefore, the basement, below:

 

So...This is the general level. Lights are at 50 degrees off so that they look like the hitbox is *actually* correct - I think technically it's based off of 0 degrees, but this looks better overall.

Only one level at the moment (And two level of lights, so I have to fix that once L’Joe there is in the game), but L’Joe is stuck here, and isn’t about to try and get out, however. Plenty of food stored below, I guess.

 

L’Joe is imaginative though, and so with his trusty red phaser (Don’t think Star Trek “Switch to stun” phaser, Think Men In Black 3 “mind-wiper” phaser [Speaking of… http://www.youtube.com/watch?v=IyaFEBI_L24 ]) is out to vanquish them.

 

So…the enemies are imaginary (Although I really hope to actually have them in the game), and his Phaser will shoot out red shockwaves in the direction he’s facing.

 

Pretty much it. Hope to actually get the functionality working (Player first, along with ground detection and jumping – then enemy spawning and hit detection, finally going for phazer attacking. Up until then, it’s all in his imagination. <_< Oh, except for the whole “locked in a basement” part. That actually happened.), then possibly move to a title screen, as I mentioned in a previous post, where the character, after you select play, will walk and jump over the start text, use the phazer to destroy an enemy, then walk over the edge of the screen, flip a switch (Making the rest of the screen go dark) , then walks off.

 

That would be optimistic though. Probably just him walking around (No animation, even, I’m willing to bet).

 

Still enjoyed what I did this competition though (Namely, how to go full AS3.0 and make it work. Well, I imagine technically the .swf isn’t AS3.0 since there’s the main frame code there, but good enough for me at this moment.).

 

 

 

Oh Yeah? You and what army?

So…calling it quits for tonight, hopefully will get it working today before 5.

I’ve the got (un-animated) player on the field, but I’ve been trying to control his gravity with the AS3.0 Tween object – I can make him go up on command at a defined rate (Think Old Arcade Donkey Kong – jump is always the same height, and always goes down at the same rate, only if he falls further does he fall further.), but I can’t get that to work with the “Hey! You’re hitting the ground! Stop falling!” code.

 

Been trying to use the character’s y value (Based off of his shoe right now, if I’m not mistaken) + 2 (Since going downwards means adding to the y-value…yeah, really annoying when all math courses do it the other way around…but you learn to eventually re-program oneself that way.) to account for the ground (So technically, floating two pixels above the ground), and then stopping the gravity tween object. But it’s not stopping!

 

It actually appears to be that my per-frame check isn’t kicking in, and I can’t find out why. So going to take a look at that…at like 12 noon, in 8 hours or so. Right now I need to rest.

 

You can find the code here:

http://www.sfu.ca/~ajr12/LudumDare22/NearBeta/

 

As you can probably guess, yeah…no army of enemies this time around. Might do this in my spare time for fun instead, however. I do like my approach to the theme.

 

After I get the jumping to work, I’ll be working with the HTML holder for it, I guess. Actually, no. Doing that now. Getting it over with.

 

Hopefully see you all in 8 hours!

 

 

L’Joe is a real boy now!

So…two hours before deadline, but I has something now! I has movement!

 

And Gravity!

 

And….PLATFORMS!

 

So that makes this a platformer then. This is close.

 

Source:

http://www.sfu.ca/~ajr12/LudumDare22/Beta/

 

 

 

Right, so now would be the time to add enemies, IIRC. Or…yeah. Then let them collide with the player to “kill” him, or collide with the lights to change how they’re working.

 

Um, but first:

 

Tween examples:

 

http://www.republicofcode.com/tutorials/flash/as3tweenclass/

 

So this is where I got my tween code to work from – the basic premise is that, when the character jumps, it calculates his max jump, then motion tweens him to there.

 

When that finishes, that tween object that did that throws an event that I listen for that triggers him falling, with another tween.

And that tween has a listener that goes off every time the above falling tween moves, and checks to see if the character’s hitting an object – if it is, then it puts him above the object. (Might remove that last step if I felt this wasn’t going to let them fall into the ground.

 

ANYWAYS, I do a check every frame (Finally got this part working), and if neither of the above tweens are playing, and the player isn’t touching ground, then I make him activate the falling tween. So…Gravity. It works.

 

Writing that down so I don’t forget next time I do Ludum Dare, because I probably won’t finish properly next time.

 

Blue ground, floating platforms, and second floor shown now. Also, L'Joe on scene.

Enjoy!

Download Complete – Out of Memory Exception

So…tried to add enemies, and gave them movement and such…

 

Turns out, they leak memory. Or at least, somewhere I have too much memory (Probably the background), and it’ll die out. Could just be the reuse of tweens I do are causing it, but eh, this is good enough for me. I’m happy with how the code is done.

 

Dunno why the leak though, and that’s a problem, so I just disabled the enemies all together in the final copy.

 

Source:

http://www.sfu.ca/~ajr12/LudumDare22/Final/LudumDare/Final/Source/

 

Final Game Version:

http://www.sfu.ca/~ajr12/LudumDare22/Final/LudumDare/Source/LoneShadowAlpha.html

 

 

 

So yeah – right now, essentially you can walk around and jump around, and gravity can affect you if you try to hover in the air, but yeah.

 

Might do a de-brief later if I have time, but not much else to add.

 

Yeap.

 

Enjoy!

LD23

I’m in Ludum Dare 23

Heya all.

 

Yeah, I’m back in for this one.

 

My main changes to my goal are to polish up the AS3.0 transition I made last time and go for adding in Fixel into my programming setup. Looking forward to adding those tools.

 

Although Chevy’s FlashPunk has me thinking I might use that instead. It really depends on which one I can use better.

 

That’s it for now – if you want to see the details I outlined last time (Since I’m going to probably do something similar – still playing Star Ocean: The Last Hope on a first run because I was delayed for a while with a broken PS3), they can be found here:

 

http://www.ludumdare.com/compo/2011/12/13/ludum-dare-22-im-in-2/

 

Hope to enjoy doing this again!

 

P.S. Thank goodness for no cats this time around. :p

 

It’s a Small World afterall!

Alright, so the theme is “Tiny World”. Personally not huge on the idea of a tiny canvas, so…there’s my antagonist. :p

 

I’ll probably take this the “Top-down RPG”-esque route, with some inspiration from Jade Empire’s jumping mechanics to act as a way to get out of trouble.

 

The idea would stem from the basic plot that the world is beginning to shrink, and so a scientist has shrunk you to buy you time while you prepare to fight whatever is shrinking the world.

 

So now I just need to get my external engine working, and I should be good to go. Going to try and Google up some tutorials on how to get started with them – I know basic Actionscript 3.0, but not how to properly import libraries in. At least, I think. I’ve done some work with the Click API for Scaleform recently, so hopefully it’s something like that.

 

If you know otherwise, please feel free to let me know. I’m currently giving Fixel a try, but willing to try whatever has the least resistance.

The Ants go marching one by one to face the flood!

Okay, more or less starting from scratch again as far as game development goes on the engine side – it does look like I’m going with Flashpunk this time around.

But, something did stick, and I’ll link it here:

 

http://active.tutsplus.com/tutorials/workflow/how-to-use-an-external-library-in-your-flash-projects/

 

This details how to use an external library in Flash, and it does appear to work, although the FlashPunk engine appears to want you to use it outside of the Flash CS3 environment. Currently waiting on a confirmation that I’ll need to leave it for this, although I’d like to stick within it if possible. I just have it already installed and know the system better, is all.

 

~~~~

 

In the meantime, I actually know more about the gameplay elements I want to use, and the plot of the game.

 

So, you’re on Pangea,  the supercontinent caused by merging all of the current continents, and a demonic meteor crashes down on the edge of the effectively one ocean, causing mass flooding, as well as melting the ice caps, thus causing extreme flooding of the world. Humans are nearly obliterated, everything up to the cockroachs are near extinction.

 

So clearly, it’s up to the ants to defeat the demonic presence in the meteor and restore the Earth’s natural order. So get ready to roleplay a worker ant.

A bit of Pikmin minus the Pikmin, I suppose, as you go about to various dungeons collecting materials to enhance your already super-strength and all that, until the colony can develop a boat with which you sail out and tackle the menance.

 

Planning to make the game at most an hour of gameplay, as the water will constantly rise and block off areas, and you need to strategically find ways to solve puzzles to get things like an ant-spear, a magnifying glass, and a piece of ant-chainmail, before you take off and fight a giant boss fight.

Mostly chose ants because of the idea that they can lift 20 times it’s weight, and wanted to make gameplay that focuses somewhat on that aspect. Either lifting rocks out of your way and/or using them to attack enemies, as well as the *completely un-researched* idea that because of this, they make great ninjas, and can jump over obstacles in their way during combat. Sort of emulating Jade Empire’s dodge mechanic in top-down form, allowing you to jump over enemies to get out of being cornered. Perhaps even tie this to the “Bonus Board” idea from Star Ocean: The Last Hope idea.

~~~~

 

Of course, to do this, I need to get started. But I’d thought I’d write this down for now, at least. I’ll probably start actual coding at around 10:00 a.m. PST, since I’m feeling that I may not be as productive today. But at least I have a plan, right?

Not successful!

Unfortunately, I am not going to be able to complete this Jam – I spent most of yesterday setting up FlashDevelop, as it appears that I do indeed need to get away from the Flash CS3 environment.

 

As a result, I knew I wasn’t going to be able to make enough headway for myself to be satisfied, so I’m spending this weekend just learning the quirks that change (For example – it looks like I can’t use MovieClips to control animation.).

 

Good luck to everyone else!