Be a Supporter!
Response to: The Flash 'Reg' Lounge Posted April 10th, 2014 in Game Development

At 4/10/14 11:18 AM, MSGhero wrote: var a = [for (i in 0...100) if (i % 2 == 0) i];
Lib.trace(a); // 0,2,4,6,...

It'd be nice if the IntIterator included a step variable rather than just a min and max.

From Nic on underscores:
"Syntax is a not beauty contest, it's here to express a given semantics,
and while sometimes we need to abstract things out to write quick
programs (such as for...in), most of the time, having the syntax
expressing what will actually happen at runtime.

That's why I'm still in favor of using get_xxx/set_xxx, because we need
to create actual real methods that will be callable at runtime and
visible through reflection. Hiding them by using abstract concepts will
just trigger more misunderstanding by the haXe user."

Generally, what are your opinions on using essentially empty getters and setters? I should definitely start using the correct syntax for them, but the only time I use them now is when I need to do some checks or calculations before setting and getting. If they're empty (return x, x = X), then I really see it pointless and just set the scope to public.

At 4/10/14 10:23 AM, Sam wrote:
You could make a public var with set access set to "never." It would still be gettable from within subclasses, but setting would throw an error.

Good to know.

Response to: The Flash 'Reg' Lounge Posted April 10th, 2014 in Game Development

At 4/10/14 10:41 AM, GeoKureli wrote: switches without breaks, what if several groups of values have the same outcome?

I don't quite understand. The breaks are implied, if you wan't the same effect as a fall-through switch case:

switch(value)
{
    case c1, c2:
        trace("Matched");
}
Std.is (vehicle, Car)
why not just make a it a damn operator?

Yeah, I find it strange it's not an infix operator.

var car:Car = cast vehicle;

why change it at all.

I'd much a C-like cast

(Car) vehicle;
public var x (get, set):Float;
function get_x ():Float { return _x; }
function set_x (value:Float):Float { return _x = value; }

I'm half for this and half against it, but why the underscore in the function name?

Do they have to have the underscore? I'm really not sure, I tend to just write my own getter and setter which aren't actual proper ones (I'm such a bad programmer).

basically, if ou have the ability to change AS3 to look like this, why not just make it look like C#?

Good points:

function hello (msg:String):Void {}
var type:String->Void = hello;

that's just genius! maybe even better than C# delegates.

Someone correct me if I'm wrong, but is this functions being "first-class citizens"? Anyway, agreed, it's nice. The functional programming module I took actually might help me with something after all!

I heard Haxe has some crazy for loop style inline array declaration, so I can create a for loop with ordered multiples of 2 up to 100. is that a thing?

I know you can do that with lists in Python, but I've not tried or seen it done in haXe.

Response to: Sponsorship advice? Posted April 10th, 2014 in Game Development

To actually answer the questions in your original post.

What sites should I contact about flash game sponsorship?

Any you can find. The more you contact, the better chance you'll have of a response. Have a look at some of the "top rated" or "featured" games on their website; if they tend to be large games and your game is a small puzzle game, you may not have the best chance of a sponsorship deal - but it still won't hurt to contact them.

What sites are most likely to actually respond?

It all depends on what your game is like. If it's extremely high quality, you could have many larger sites fighting to get it. If it's a smaller game or you're just starting out, smaller to medium websites will be more likely to respond.

What sites are most reliable?

This isn't something I feel I can comment on. If you're doubtful, their may be more information online. You can always ask in forums before making the deal to see what others have to say about them.

How much money is it possible to get from this?

Anywhere from $1 to $10k's. The quality of your game directly affects how much money you can make from it. (along with other factors, obviously).

(I know I am not a GREAT/GOOD developer but I figured I might as well give this a go, I need some money at the moment and this is the only thing that comes to mind (I know about FGL, but ehhh..))

The best thing you can do is talk to people about your game. Get them to play the game and give you criticism and comments - every opinion is valid because those people are going to be your target audience.

This seems like a good article, but I haven't had chance to read it thoroughly so take that with a pinch of salt.

Response to: The Flash 'Reg' Lounge Posted April 10th, 2014 in Game Development

At 4/10/14 10:16 AM, GeoKureli wrote: can you still use traditional for loops?

That is the traditional for loop. It feels very "psuedo-code"-y, but at the same time, I quite like it.

Also, this is fucking stupid

switch (value) {

case 1:
trace ("Equal to 1");

default:
trace ("Not equal to 1");

}

Why is this stupid?

apart from your egyptian braces </3

One thing that I think is a bad design choice is the omission of the protected keyword, and the change of the private keyword to be what protected means in AS3.

Response to: Sponsorship advice? Posted April 10th, 2014 in Game Development

At 4/9/14 07:48 PM, CrazyRock wrote:
At 4/9/14 07:44 PM, MSGhero wrote:
At 4/9/14 07:35 PM, CrazyRock wrote: All advice & links are appreciated!
https://www.fgl.com/, otherwise just send a message to the popular portals and some of the less popular ones.
I know about FGL but it's never a safe bet on there. It can pass by unseen or the sponsors that view it just aren't interested while someone who might be misses it... That's why I asked here about some helpful information on contacting websites individually.

Construct an e-mail template to send out to sponsors. Be professional, but to the point - play to the advantages of your game (sequel potential, high replay value, deep constructed story), what makes your game stand out? Offer the .SWF as an attachment as well as a URL. It's also worth being clear about how much exposure the game has had prior, as most sponsors want only one version of the game on the internet: the one with their branding on it. You could also talk about what kind of sponsorship deal you're looking for (exclusive/non-exclusive)

Use this template for each e-mail you send out, but make sure you personalise it to each sponsor you contact. At the very least, address the sponsor by name.

Response to: Make Money - Switch To Html5! Posted April 10th, 2014 in Game Development

This forum is for discussing Flash, Flex and Air development and ActionScript 1 through 3, not for your to advertise your website and sponsorship opportunities for a different platform.

Response to: Reset enemies and props in As3 Posted April 10th, 2014 in Game Development

Simply add them again. If you're using a mixture of the Flash IDE (i.e. frames, placed movieclips etc) and code to build your games, I'd highly suggest moving over to something like FlashDevelop and only use code to build your games.

Response to: The Flash 'Reg' Lounge Posted April 10th, 2014 in Game Development

At 4/10/14 03:42 AM, egg82 wrote:
At 4/10/14 03:22 AM, PSvils wrote: http://www.openfl.org/archive/developer/documentation/actionscript-developers/
Well, THAT'S just taking the piss.

The only thing I don't like is that you can't iterate backwards like 10...-10

Response to: charCode for arrow keys trace as 0 Posted April 9th, 2014 in Game Development

You want to compare the value of:

e.keyCode
Response to: Flash CC worth it? Thoughts? Posted April 4th, 2014 in Game Development

At 4/4/14 05:25 PM, MSGhero wrote:
At 4/4/14 04:03 PM, Sam wrote: It's more likely a better option to export your animations as sprite sheets and work with them. I haven't personally looked into using SWFs and SWCs with OpenFL because I honestly see no reason to - this link might interest you though.
Flash pro -> create swf from mc -> texturepacker -> swf plugin -> spritesheet bam. I need to hard code the registration point, that's the only thing.

Wait, so the end point is a spritesheet anyway? Why not just directly generate the spritesheet from Flash?

am i misunderstanding? :(
Response to: Flash CC worth it? Thoughts? Posted April 4th, 2014 in Game Development

At 4/4/14 11:02 AM, davidgilbert wrote:
At 4/2/14 01:50 PM, Aprime wrote: HTML5 and it turns black... that's all I know about it
I apologize for my ignorance, but what does "HTML5 and it turns black" mean?

I think he's referring to the HTML targeting with haXe and OpenFL , which is still in its infancy and therefore often compiles and shows just a black screen in the browser. There's an alternative HTML5 backend called bitfivewhich is much more developed (but as far as I know, still not perfect).

At 4/2/14 07:52 AM, Hero101 wrote: Question: If I were to code in openFl could I still do all the visual stuff (movie clips, timeline, etc..) inside of my Flash Pro CS6 and some how link the code written in openFl to the swf? Forgive me if that's what you meant when you said "you can use swf files as assets".

It's more likely a better option to export your animations as sprite sheets and work with them. I haven't personally looked into using SWFs and SWCs with OpenFL because I honestly see no reason to - this link might interest you though.

I'd recommend making the move to haXe and OpenFL as soon as possible and adapt your workflow.

Response to: The Flash 'Reg' Lounge Posted April 1st, 2014 in Game Development

At 4/1/14 02:38 PM, MSGhero wrote: I don't call super in the create method of FlxState, I just override it and add content.

Turns out it was due to our zoom level being < 1 - also removed the super.create() in our classes extending FlxState.

Response to: The Flash 'Reg' Lounge Posted April 1st, 2014 in Game Development

Could anybody with haXeFlixel or flixel experience take a look at this thread? Me and my house mate are trying it out but this problem seems really strange. We have no flixel experience, so we might be doing something obviously wrong but the demos don't seem to do anything special. Cheers!

Response to: The Flash 'Reg' Lounge Posted March 31st, 2014 in Game Development

At 3/30/14 09:38 PM, Innermike wrote: iOS Game

I'm not a huge fan of the font, but the UI as a whole looks really clean. Any chance we could get a video of the gameplay?

I've been reading a lot for the last few weeks, trying to get uh, not inspired necessarily but some perspective I guess.

This is something I've been trying to do as well. I've read a few books on recommendations from friends, but some of them just aren't my style I suppose. I've visited 4chan's /lit/ board and picked up their "starter kit" of books, and will probably start reading them during summer. A handful of them being: "A Clockwork Orange", "Do Androids Dream Of Electric Sheep?" and "Fahrenheit 451".

Forum rename
Considering the posts about Flash dying and stuff, it reminded me of when Tom was thinking about renaming this forum to just "Game Design" or something similar. What are your (as regulars) views on this?

In other news, brushing up on my Python (and then hopefully transition into Python for server-side work) after I did some web work in PHP and came across more and more problems that @Diki has pointed out to me in the past. I'm sure there are people who can write PHP well, but to me, the language feels utterly broken and because of how large the programmer base is, the percentage of people who can actually write"good" PHP has become smaller and smaller. I also feel the same about Java, but I feel it's less broken and more "trying to do too much" and partially inconsistent from my own experience.

So this also leads me to ask: What are your favourite languages and why?

Response to: The Flash 'Reg' Lounge Posted March 27th, 2014 in Game Development

At 3/27/14 04:51 PM, Sam wrote: Any bets on the successor to Flash? The way you talk of the Unity workflow, do you think Unity player is more likely than something like HTML5, @Glaiel-Gamer?

Flash as in the Flash Player, not the Flash IDE and its workflow.

Response to: The Flash 'Reg' Lounge Posted March 27th, 2014 in Game Development

Any bets on the successor to Flash? The way you talk of the Unity workflow, do you think Unity player is more likely than something like HTML5, @Glaiel-Gamer?

Response to: The Flash 'Reg' Lounge Posted March 26th, 2014 in Game Development

I spent ages trying to justify some reasons as to why Adobe might develop AS4 - something to do with opening the floor for other languages such as haXe to target the flash platform by writing it more "low level" or something. But in the end I kinda just realised - haXe is awesome, but the majority of the reasoning behind it is because it can target so many platforms. It'll be a real shame if the flash platform has to be crossed off that list.

I just think I have too many ties to Flash as a whole so I may be slightly biased. In my eyes, it's a really valuable asset and while it may be "dying", it isn't too late to save by any means.

Response to: Looking for Programmers/Animators Posted March 23rd, 2014 in Game Development

So if you're looking for programmers and animators - what will the current team (as it stands) be doing?

Response to: Programmer Needed!!! Posted March 23rd, 2014 in Game Development

Limiting to AS2 might deter programmers. Is this a necessity? If all you're providing is the art assets then surely the programmer can work in any language they feel comfortable.

Response to: The Flash 'Reg' Lounge Posted March 22nd, 2014 in Game Development

At 3/22/14 12:57 AM, egg82 wrote: Some of they changes they made looked amazing, I'm not sure why they stopped.

I do wonder. Do you think it's a money problem? I mean, there are a load of better programming workflows than the Flash IDE. I'm not sure what other animation software is like, though. Maybe they're not making the sales they want with Flash.

Response to: Haxe/openfl 101 For Flash Refugees Posted March 19th, 2014 in Game Development

Really great article. I'm looking forward to the future of haXe and OpenFL, a lot of devs have already made the change and at least for me, it was almost completely painless.

Response to: Java programming Posted March 19th, 2014 in Programming

Newgrounds only accepts SWFs, so the JAR files that your project would produce won't work.

Response to: The Flash 'Reg' Lounge Posted March 19th, 2014 in Game Development

At 3/19/14 10:33 AM, Sam wrote: I was attempted to anything and put a note to my lecturer saying "Can I have a point for trying?".

I royally fucked that sentence up. * "I was tempted to put anything and put a note..."

Response to: The Flash 'Reg' Lounge Posted March 19th, 2014 in Game Development

At 3/17/14 02:05 PM, MSGhero wrote: If you answer that, you also get a million dollars. One of the 7 millennium questions or whatever.

I was attempted to anything and put a note to my lecturer saying "Can I have a point for trying?".

In other news, I hate Java. It's without a doubt the worst language I've worked with so far. :(

Response to: Big organization question - AS3 Posted March 18th, 2014 in Game Development

At 3/17/14 03:17 PM, Barzona wrote:
At 3/17/14 01:54 PM, davidgilbert wrote: Instead, they should be pushed into the levelArray property using a for loop in the class constructor. After you push level1, level2, and level3 into the array you can access them using levelArray[0] (which is the same thing as level1) levelArray[1] (same as level2) and levelArray[2] (level3).
Actually, they were being pushed into the array in the part of the code you couldn't see (since it wasn't part of the topic). I do actually know that much about code.

But why not:

levelArray = [new Level1Container(), new Level2Container(), new Level3Container];
Response to: The Flash 'Reg' Lounge Posted March 17th, 2014 in Game Development

I really need these 1,000,000 points for a module I'm taking.

pls halp guise

The Flash 'Reg' Lounge

Response to: As2 Dynamic Text Clock??? Posted March 15th, 2014 in Game Development

At 3/15/14 12:13 PM, Madjasper1 wrote: What the fucking hell?

You must not be embedding the font properly, look here: Embedding Fonts

Response to: Virtual Currency platforms Posted March 12th, 2014 in Programming

At 3/12/14 06:36 AM, HydraliskD wrote:
At 3/11/14 01:50 PM, Sam wrote:
At 3/11/14 10:49 AM, HydraliskD wrote: Hi guys! Need some help for my indie-project. We wonna implement virtual currency in our game, so could you tell me any platforms for VC issuing? And your experience with it?
Virtual currency? Do you mean a digital currency like BitCoin or a currency you distribute and control?
We want to implement some system which will give ability to input real cash in game and convert it in game-currency (gold or smth like that) and buy staff with it. Maybe you could recommend "ready" desicions? Thank a lot!

The only platform you need to leverage is some sort of payment platform such as PayPal, which with their API is extremely easy (or so I've been told).

Essentially you'd have a database which stores the users of your game and how much in-game currency they have and what have you, and then the "buy in-game currency" steps might be:

1) Player click "Buy X of in-game currency for Y real currency"
2) This gets sent to some payment system (such as PayPal)
3) The player signs in and confirms the payment of Y to your (companies) account
4) On the success callback from the payment system, add X amount of in-game currency

With the final step increasing the players in-game currency in the database.

Response to: Depth sorting... Posted March 12th, 2014 in Game Development

Alternatively for sorting based on Y, you could do something like this (although I don't know how quick the sortOn method is):

characterArray.sortOn("y", Array.NUMERIC);
for (var i:int = 0; i < characterArray.length - 1; i++)
{
	if (getChildAt(i) != characterArray[i])
	{
		swapChildrenAt(i, getChildIndex(characterArray[i]));
	}
}
Response to: Virtual Currency platforms Posted March 11th, 2014 in Programming

At 3/11/14 10:49 AM, HydraliskD wrote: Hi guys! Need some help for my indie-project. We wonna implement virtual currency in our game, so could you tell me any platforms for VC issuing? And your experience with it?

Virtual currency? Do you mean a digital currency like BitCoin or a currency you distribute and control?