Recent posts by Glutenfree4u on Kongregate

Flag Post

Topic: Game Programming / Graphic glitch when switching browser tabs.

It might be the way you are embedding the swf. Try googling the best way to embed swfs on an HTML page.

 
Flag Post

Topic: Game Programming / Graphic glitch when switching browser tabs.

This happened to me once, but went a way after a bit. Are you using an old version of Flash Player? (for your swf export or your personal player).

 
Flag Post

Topic: Game Programming / as3 what is the most efficient way to use enterframes

Originally posted by Aesica:

Kind of like this:

	public class GameContainer 
	{
		// vector (or array, if you must) that you will populate with objects that need to execute something every frame
		private var aBunchOfGameObjects:Vector.<GameObject>;
		
		public function GameContainer() 
		{
		}
		
		// this is a single enter frame function
		private function FrameHandler(e:Event):void
		{
			var i:int;
			var iLength:int = aBunchOfGameObjects.length;
			
			// cycle through all of your game objects, or whatever, and do stuff with them
			for (i = 0; i < iLength; i++)
			{
				aBunchOfGameObjects[i].StuffToDoEveryFrame();
			}
		}
		
	}

Also don’t forget to remove any event listeners for objects you no longer have references to. Excessive enter frame events will lag you, not removing event listeners will lag you too, because they (annoyingly enough) don’t clean up on their own.

Also, about weak references: It’s my understanding that weak references are NOT self cleaning either. What they do is allow an object to be collected if no other references to it remain. The listener itself still remains though.

That’s awesome, I never thought of just running all of those functions with 1 enter frame, I assumed it would lag just as bad as all the other enter frames.

 
Flag Post

Topic: Game Programming / People are losting gave save

I’m not quite sure but I’m pretty sure ISO.getLocal() should only be called in the variable definition.
That could be totally wrong what I just said there, so please someone correct me if I’m wrong.

But here’s the way I save stuff in my games, the save system you’re using seems to be filled with a lot of useless stuff:

var SO:SharedObject = SharedObject.getLocal(“game_name”);

function saveGame() {
SO.data.playerX = player.x;
SO.data.playerY = player.y;
SO.flush();
}

function loadGame() {
player.x = SO.data.playerX;
player.y = SO.data.playerY;
}

You could change out the number values with whatever you wanted (booleans, strings, etc).
Hope this helped!

EDIT: Added in .data’s, sorry, typo. (tested and it works now)

 
Flag Post

Topic: Game Programming / Feedback to my new game (critics are very welcome)

it’s okay, but honestly Mario ripoffs are the worst types of games, because there isn’t really any surprises, we pretty much know what the game is like already, because we’ve seen so many.
I’d really suggest trying to come up with a different type of game to do as your first, I know my first was a rip-off too but it was a more complex game that I was trying to duplicate, so it was a way better learning project than Mario.

Also, generally people won’t try out your game because it is on a website they have never heard of or been to before. Maybe next time you could post us a Kong link too?

 
Flag Post

Topic: Game Programming / looking for tutorials.

https://www.google.com/#q=flash+builder+game+tutorial
Google is your friend.

 
Flag Post

Topic: Game Programming / how do you add two numbers in c++

Try doing 1 + 2…

 
Flag Post

Topic: Game Programming / What's with all the hate on Unity?

Originally posted by pugzy:
Originally posted by Glutenfree4u:
Originally posted by pugzy:

Flash crashes all the time, and doesn’t tell you why it crashes either. The only reason no one complains about it is because it’s so old compared to things like Unity.

Why people don’t complain is because it only happens on games made by a bunch of noobs who didn’t optimize a single thing.
Plus, by your point of reasoning, we shouldn’t be complaining about our PC’s crashing because they are old. (even though they are regularly updated)

And being old and regularly updated is a good thing, it means it is usually a lot more stable than something new. (since new things still have a lot of work to be done)

That wasn’t at all what I meant when I said “old”. Not to mention that the optimization part was false. I’ve had Flash crash on sites like YouTube, for just watching a video. I mean, I guess Google might be terrible at Flash programming, I just highly doubt that, given the power of their engineering force.

What I meant by older, is that everyone has known Flash for practically most of their computer lives now. You already somewhat know how Flash and Flash Player should work and how well applications are going to run, etc. Unity came out in what, 2005? They probably didn’t even expect Unity to get known at the time. Not to mention, compared to Flash, it’s still new. Also, when you look at some of the “features” Unity has over Flash, it’s not too much of a surprise. Unity is more of a game engine than Flash, Unity does a lot more than Flash does for you. Physics? Unity does that. Multiple scripting languages? Unity does that.

You shouldn’t complain if you PC is crashing because it’s old, because hardware can only do so much, before software updates stop allowing newer technologies to run as easy. You don’t expect a 16 bit processor to execute 32 bit or 64 bit code do you? Then don’t expect software to fix crashing on an old system. This happens all the time with things like main frame computers in businesses, etc.

Originally posted by Glutenfree4u:

I totally agree. Doesn’t matter what game engine you’re using, if you don’t optimize your game it’ll turn out crappy.

Optimization doesn’t make a great game. Optimization only makes code execution smoother. If you don’t animate your 3D models in a game that would look so much better with animations, there’s no amount of optimizations you can do that will make that aspect of the game better.

I didn’t say it was the only thing that makes it good. What I said is true, is it isn’t optimized it’ll most of the time be laggy, and laggy is bad, thus, your game is bad.

I did not say: All you gotta do is optimize and your game will be awesome. No need for animations people, let’s get optimizing! Haha noobz who think they need artz in their gamez.

Please, oh please I beg of you, everyone please stop putting words in my mouth. Read the post all the way before you make your reply.

YouTube is just one site, don’t judge the engine by it’s programmers. Flash is good and can make lots of good things, but if you don’t do it right (like with anything), it’ll turn out bad.

 
Flag Post

Topic: Game Programming / What's with all the hate on Unity?

Originally posted by Draco18s:
Originally posted by AnTi90d:

I never have any trouble with Flash player. It doesn’t crash on my system. If I ever did have a problem, though, it isn’t that hard to fix. Flash is an established product and you can find support for it in many places.


I have written a Flash application that crashed Firefox, PluginContainer sandbox security be damned.



People aren’t raging about Flash games being Badges of the Day.

They do, actually. 99% of games that get badges drop in rating by a quarter to half a star for a variety of reasons.

Originally posted by Glutenfree4u:

Why people don’t complain is because it only happens on games made by a bunch of noobs who didn’t optimize a single thing.

Same thing for Unity. There are dozens and dozens of optimizations I learned about only after producing two games with it. The first one is actually here on Kongregate (it was polished up with a nice GUI later, as it was something I did just to learn Unity and it got branded, so I couldn’t put that version on Kong). The second game was never really finished. It’s little more than a shiny tech-demo, but it did get the optimizations it needed to run on an iPad, where the first one did not.

Unity makes it very easy to do whatever you want, but doesn’t provide any optimization tools (you have GameObjects and….right, just GameObjects). Flash handles much more of the optimization itself, although there are easy-to-use better solutions (i.e. Movieclips are fast to get started with, bitmaps are optimized and require remarkably little work to use instead).

I totally agree. Doesn’t matter what game engine you’re using, if you don’t optimize your game it’ll turn out crappy.

 
Flag Post

Topic: Game Programming / What's with all the hate on Unity?

Originally posted by pugzy:

Flash crashes all the time, and doesn’t tell you why it crashes either. The only reason no one complains about it is because it’s so old compared to things like Unity.

Why people don’t complain is because it only happens on games made by a bunch of noobs who didn’t optimize a single thing.
Plus, by your point of reasoning, we shouldn’t be complaining about our PC’s crashing because they are old. (even though they are regularly updated)

And being old and regularly updated is a good thing, it means it is usually a lot more stable than something new. (since new things still have a lot of work to be done)

 
Flag Post

Topic: Game Programming / How I can make a game like Bob The Button?

Erase Adobe Flash Professional from memory too, we are not talking about that. We are talking about Flash Develop (not made by adobe).

 
Flag Post

Topic: General Gaming / Learn to fly 3

Yeah he got the money and is working on the game.

 
Flag Post

Topic: Collaborations / Looking for someone to make some simple 3D models

This should be pretty easy for an experienced 3D modeler, but I’m trying to make a paper kinda character for my 2.5D game I’m working on, but suck so bad at 3D modeling, so I need someones help! PM me if your interested.

 
Flag Post

Topic: Game Programming / How I can make a game like Bob The Button?

@Gabidou99
Alright, well sorry but you’ll have to post in a Stencyl forum then, I’m pretty sure everyone here is a programmer.

 
Flag Post

Topic: Game Programming / How I can make a game like Bob The Button?

http://get.adobe.com/flashplayer/

Install that to test your game. Is flashdevelop exporting any file with .swf at the end? Double click it once you’ve got FlashPlayer installed and it’ll open in it in FlashPlayer or your browser.

Really, please, do not use Stencyl. To program a button game will be easy. Install FlashDevelop (not Flash CC/CS/Builder, they cost money) and look up some starter tutorials for it, once you have the basics down I will be able to show you how to make your button game and it’ll be easy. It probably won’t require more than 50 lines of code.

Here’s a starter tut:
https://www.youtube.com/watch?v=RqTuS3ReiW8

Just google “flashdevelop beginner tutorial”, you’ll find a lot more.

 
Flag Post

Topic: Game Programming / What's with all the hate on Unity?

Haha, nice.

 
Flag Post

Topic: Game Programming / How I can make a game like Bob The Button?

Have an array:

var myArray:Array = new Array();
mArray = [“some text”, “another possibility”, “yet some more text”, “moar text!”];

button_mc.addEventListener(MouseEvent.CLICK, clickButton);

function clickButton(event:MouseEvent):void {
textField_mc.text = myArray[Math.random() * myArray.length];
}

I didn’t test it, but should work, just make sure these 2 things:
You got to have a textfield and a movieclip on the stage, name the textfield textField_mc, and name the movieclip button_mc.

 
Flag Post

Topic: General Gaming / LittleBigPlanet 3 is coming out for Ps4!

LBP3 was just announced at E3 a few days ago, lots of cool new stuff in this one, such as 16 layers, over 60 new gadgets, and creating your own power-ups! It’ll be coming out this november.

What do you think about it?

 
Flag Post

Topic: Game Programming / Unity NetWork MultiPlayer

Here’s something that helped me:
http://www.paladinstudios.com/2013/07/10/how-to-create-an-online-multiplayer-game-with-unity/

 
Flag Post

Topic: Game Programming / What's with all the hate on Unity?

@ADM No, when I say all you have to do is export for CreateJS I mean it. You can code in AS3, make timelines, have tons of vector stuff, all you got to do is export for CreateJS. That’s why it’s called CreateJS.

 
Flag Post

Topic: Game Programming / HELP

It’s completely free.

 
Flag Post

Topic: Game Programming / What's with all the hate on Unity?

Nope, I’ve followed some tutorials before, you just code like you’d normally do. It exports the code and everything.

 
Flag Post

Topic: Game Programming / What's with all the hate on Unity?

@Drakim
In Flash just export with the CreateJs feature, it’ll export it as a javascript/html5 game.

Everyone keeps saying flash is dying… It’s not flash that’s dying, but actually, swfs are dying. It doesn’t have to be a swf to be flash. I could make the most complex game in Flash As3, and simply export it for CreateJs and everyone could play it, whether they have flash or not.

And addressing the original question in this post:
Unity isn’t bad, but it isn’t exactly finished. It does seem to crash a lot more than other things.

Unity is good for a lot of things, but if it’s a web game, Unity probably isnt the way to go. Many people still don’t have Unity installed, and so that is also a reason why people are hating. They want to play the unity game, but they have no idea what unity is, and no idea if it’s a scam.

 
Flag Post

Topic: Game Programming / Which Story Line do u like the best?

Story 1 is better I think, everyone likes squashing bugs, right?

 
Flag Post

Topic: Game Programming / Kong accepted Binaries

Originally posted by Deathsbreed:

Replying to player_03, on Debian Linux HaXe is extremely hard to install, which is why I’ve switched to Java. Then, as for using Flex, I don’t think Adobe is continuing development for Flash on Linux, aside from the fact that Flash is dying and being replaced by HTML5 and Javascript (mainly HTML5), so it wouldn’t make much sense.

In any case, does anyone know a website where they do accept Java Applets?

“mainly html5”…

So, if I understand you correctly flash is being replaced by a very simple programming language that is only good when being used along side other languages?

Here’s some examples of very good Flash games created recently: (after the ads (if they have them), right click it, you’ll see it says on the bottom menu “About Adobe Flash Player”)
http://ninjakiwi.com/Games/Tower-Defense/Play/Bloons-Monkey-City.html

http://www.kongregate.com/games/Ironhidegames/kingdom-rush-frontiers

http://www.kongregate.com/games/DrNeroCF/fpa-world-1-remix

Flash isn’t being replaced, and also if you’re about to say that it is because it can’t go on mobile, go into Flash and notice you can set it for Android and iOS, plus with recent updates Flash games on mobile devices no longer lag, of course like in any programming language, there are a few features that mobile devices can’t handle, but Flash is far from dead. It is not dying, or being replaced in any way.

Also about ES saying Adobe stopped developing Flash, Flash CC was released last year and there have been many updates for it, and also speaking of that, if you want your Flash games to work on mobile web browsers, use the new “Create JS” feature, and also the new HTML5 canvas. You can make your games exactly as you did before in AS, and still have them work on the mobile web browsers by just exporting them as HTML + JS.