|
Hanpan posted:I actually have no idea why I typed Flex because I primarily used the Flash IDE. Out of interest, do you have any projects you can show me? My tile engines always seem sluggish but I am more than willing to admit it's probably because I code them badly. Flash is more than capable of doing a 2d platformer, infact I would say that is is one of the better technologies to do it in, especially because AS3 is totally badical. Edit: I had typed up a hint to use copyPixels, but it seems you are already doing that, perhaps you are doing something horribly inefficient, PM me if you would like to discuss it further.
|
# ¿ Jan 14, 2008 08:51 |
|
|
# ¿ Apr 28, 2024 05:21 |
|
Sigvatr posted:Does anyone like making games, knows C or C++ and wants to make money? I will be making graphics and also have a sound and music design guy. We got that artistic stuff under our belts but need a programmer dood. Strange, I would have thought MM would've had the skill (and ego) for anything you'd want to make.
|
# ¿ Feb 29, 2008 01:57 |
|
Twerpling posted:Anyone know of the best way to implement a good FSM in C#? I am trying to make one for an XNA game I am working on but the one I always use I made in C++ and it falls apart in C# due to delegates not working the same a function pointers. If I work on this bloody thing long enough I'm sure I'll get it, but I was hoping someone would have an example of a good one already done so I can work this out faster. FSM's can be made pretty easily in a nice OOP way, create a State interface, with methods like "Start, Run and End" and then just have a FSM class that does all the transitions by calling the right functions. Then its just an issue of making a bunch of different classes to do the things you want.
|
# ¿ Mar 30, 2008 05:57 |
|
Pfhreak posted:To be entirely correct, you should probably make a state abstract base class rather than a state interface. (Remember, C# has an interface keyword.) Ah, my bad, I'm not a C# programmer, we don't have thems fancy abstract classes in AS3.
|
# ¿ Mar 30, 2008 07:03 |
|
Canine Blues Arooo posted:Hello Gentlemen. I come to you with a very broad question in hopes that I can find a decent tutorial/example/resource on the issue. You could start by doing it in console, no need to go GUI for it. If you want full curses support: http://roguebasin.roguelikedevelopment.org/index.php?title=Java_Curses_Implementation
|
# ¿ Jun 7, 2010 16:57 |
|
MasterSlowPoke posted:Just try and make tetris or whatever. Or Pong, I find Pong is always a really good example... Hell you only really need 3 classes: Paddle, Ball and your main Pong class.
|
# ¿ Aug 2, 2010 16:51 |
|
Pfhreak posted:I'm looking to play around and implement 'boids' in actionscipt. I'd like to use the concept in a really simple game. I've used Flixel, and I kind of liked it, but I also want to know what other options are out there for generic lightweight flash platforms. What's good and what isn't? Just use the DisplayObject tree and basic Events. They're super easy to work with and will help you learn more about AS3 and Flash in general. That said, Flixel has some things right (using a single ENTER_FRAME event updating an array of objects). Flixel is great for its speed, but if you want vector boids (and I'm assuming you do, as they rotate a lot) learn some flash. Or if you just want another bitmap library, FlashPunk is supposed to be really good.
|
# ¿ Aug 17, 2010 01:43 |
|
Pfhreak posted:What are the free solutions for doing this? I've used flashdevelop, and had great success with AS3 there, but what would I use for the vector graphics? FlashDevelop is perfect. You can either draw with Flash's Draw API: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/display/Graphics.html?allClasses=1 If you go this route, use the lightweight class "Shape" and add it to the display list. or embed SVG which you can edit with free SVG editors like Inkscape: http://www.streamhead.com/how-to-use-vector-graphics-in-flashdevelop-svg-in-flash/
|
# ¿ Aug 17, 2010 22:58 |
|
Pfhreak posted:TL;DR: I suffer from apparently random methods taking 4-10 times as long to run. Could it be the garbage collector? How can I know? You say you're creating a 2d array every frame, but then that you're suprised that you're GC'ing every few frames. Perhaps instead of recalculating your buckets every frame you should update positions instead, so when a boid moves across boundaries, it removes itself from its bucket and adds itself to its new bucket. That should most definitely be faster. Secondly, if you're in Flash10 you can do graphics.copyFrom(source) to make a duplicate of your boid sprite from a master Shape/Graphic and just rotate the Sprite/Shape around its origin for rotation.
|
# ¿ Sep 15, 2010 01:14 |
|
nibe posted:I find myself endlessly fretting over what objects should have access to what other objects. I've got the notion in my head that less = better, but I'm not sure whether or why that is true beyond simplicity's sake. For example, I have a Unit class that represents humanoid objects that can move around. Right now the class only has information about that unit (name, position, HP, etc.) with no access to other game subsystems. But suppose I want a Unit to follow a moving target. In the Unit's update method I have to find a path to the target, which is a call to a function in the AI class. The only options I can think of are to include the AI in the parameters to Update (at which point, why not have a permanent reference), pass a permanent reference in the constructor, or move the pathfinding function call up outside of Unit into the class that has access to other things (which will fill that class with all the implementations of certain actions that can't be in the "lower" classes). I'm thinking of just passing a reference to the main game manager to everything and being done with it. Besides being highly inelegant, what cons does this solution have? Is there a better way? I'm using C# and XNA. My thought about passing a reference to a master object (containing SoundManager, CollisionManager EntityManager etc. etc.) lately has been: Pros: poo poo gets done faster Cons: Not so reusable. I was swept into the 'reuse is fundamental' argument for too long. As long as you are writing readable code, code is not going to be that hard to reuse in the next project with some tiny refactoring. But the savings from actually getting poo poo done is hard to ignore. It's said that the extra time spent making code reusable doesn't pay itself back until you use the code in 3 projects, so all the headache and messing around probably wont be useful. (I know I've never used the same code for more than 3 games) In the meantime you can do the important things like code the fun stuff instead of being stuck in refactor hell. As an aside, even the big boys cheat. Source Engine has a bunch of singleton managers.
|
# ¿ Dec 6, 2010 02:41 |
|
roomforthetuna posted:(Hasn't someone made a Flash compiler that makes an iPhone app out of a Flash thing? Won't be in a webpage but will be supporting iPhone, if you can do it that way.) Yeah Adobe did. You can package a project to iPhone in CS5.
|
# ¿ Dec 13, 2010 17:57 |
|
BonoMan posted:Should I just hire actual programmers? As a designer what would you think if I said something like: I have made a game, the functionality is all there but it doesn't look very pretty. I'm thinking of buying photoshop and playing around. I'm looking for some tutorials on the web that'll show me how to make some art, step by step. I think with a few months of messing around my art will be good enough. You'd be thinking 'oh god he has no idea what is involved in making things look good', and my art would probably be garbage.
|
# ¿ Jan 17, 2011 03:09 |
|
Gerblyn posted:I'm actually writing a TBS game at the moment and the approach I've chosen for this is to have a Unit controlled by little command data structures, which instruct it to do things like "Move to X" or "Attack Y". So, instead of calling a function like: The combination of commands and response lists are really good. The last thing you can do is combine all of them into a sort of 'event' system. Where the game listens to a set of conditions, and fires off triggers based on it. Wrapped into XML you can do fancy things like: code:
I built a really nice engine like this, it was used to produce 3 games and a multiplayer version: http://www.kongregate.com/games/urbansquall/battalion-vengeance iopred fucked around with this message at 00:57 on Apr 9, 2011 |
# ¿ Apr 9, 2011 00:30 |
|
Medieval Medic posted:
There's nothing magical, on this line, you want to call it enough times to cover every position on the sprite. The way I like to do it is something like: code:
iopred fucked around with this message at 18:55 on Oct 15, 2011 |
# ¿ Oct 15, 2011 18:52 |
|
Ireland Sucks posted:I'm trying to perform 'polygon clipping' on a triangle fan for lighting in a 2d sidescroller, but I'm having trouble coming up with a good method of doing it. Here's a great article: http://www.redblobgames.com/articles/visibility/
|
# ¿ Mar 2, 2014 19:06 |
|
|
# ¿ Apr 28, 2024 05:21 |
|
dizzywhip posted:Feel free to correct me if I'm wrong about any of this or if I'm doing something stupid -- like I said, I don't have a whole lot of experience with this sort of thing. Any resources on this subject to help me get up to speed would be really appreciated too, ideally not super long and dry if possible. Install macports, with it install pkg-config & SDL. You can then run 'sdl-config --cflags --libs' which spits out everything you need to feed to clang to compile SDL.
|
# ¿ Mar 15, 2014 07:53 |