Be a Supporter!
Response to: Newgrounds ScoreBrowser in Flixel? Posted July 21st, 2012 in Game Development

Heh, sorry for double posting, but I solved it >.<
I searched with the wrong terms.
It simply is FlxG.stage.addChild().

Sorry for bothering :S


Hey,

I wanted to add the Newground's Flash API scorebrowser to my project,
but since it is a Flixel project it doesn't work.
Does someone know how to get it working?

FYI this code is in the MainState that extends FlxState.

var scoreBrowser:ScoreBrowser = new ScoreBrowser();
scoreBrowser.scoreBoardName = "Invader Scoreboard";
scoreBrowser.period = ScoreBoard.ALL_TIME;
scoreBrowser.loadScores();
//add(scoreBrowser);   <-- Doesn't work since it is for FlixelObjects.
//addChild(scoreBrowser); <-- Doesn't work
//root.addChild(scoreBrowser); <- neither
Response to: Flash licence question Posted July 20th, 2012 in Game Development

Use FlashDevelop, it's better for making games anyways I think.

Response to: My First Game (wip) Posted July 19th, 2012 in Game Development

Thanks everyone :)

Yeah I will implement more things to the game.

I updated the game,
now there is a (at the moment pretty useless because there is only one button) menu,
but you can still press x to start the game.

Also I seperated the bullet into an extra class so I can easily make multiple bullets with more flexibility.
In this version the ship shoots with 3 bullets, just for example (it shouldn't actually be implemented).
I will somehow differ the amount of bullets, maybe automatically or somehow else.

But I have some issues with the performance, the framerate begins to sink after a time.

Anyways, don't have time right now.

Here is the link (same as the first post)
Click

Response to: My First Game (wip) Posted July 19th, 2012 in Game Development

At 7/18/12 10:19 PM, Garuflax wrote: Very well for your first game(my first game was crap xD)
If you put all you have in your list it will be like a 4 stars game.
And add a scoreboard to your "to do list"(compete with other users atracts a lot of people)

And what program you used and with AS2 or AS3?

Thanks :)
Actually with "Get some use of the score" I meant something like that.
I used AS3 with Flixel and the Flixel Power Tools for the starfield and some minor color things (ie. coloring the explosion particles randomly).

At 7/19/12 04:20 AM, milchreis wrote: But you'd be building yet another clone of this type of game with the mentioned features.

Maybe you should concentrate only on a few things.

Yeah, it's obviously a clone, but I kinda see it as an "Hello World" program or so.
Altough I will try to differ it, somehow.
Why did you include "Canabalt"? ^^

Thanks to anyone for your feedback.

My First Game (wip) Posted July 18th, 2012 in Game Development

Hey,

I just wanted to post my first game.
It is very much based on that tutorial for Flixel that milchreis suggested.
(This is the first part and that is the second one)

But I expanded it and will continue with that because
I have some ideas and yeah, why not.

Here is the link:
Dumping Grounds

To Do's (not everything is listed here):
- Add an actual menu
- Bonuses and so on
- Different projectiles
- Get some use of the score
- Somehow improve the damage effect of the ship
- A few more score parameters
- Enemies that shoot
- Find fitting and not to long music that is nicely loopable

Response to: Flash Gamemaking Guide Request Posted July 17th, 2012 in Game Development

That framework seems to be nice.
Altough he is writing object-oriented,
and I don't have a clue about how that works in Flash.
I think it would be a good idea to share the tutorials one found,
and I only found this one,
but it seems to be abandoned.
Well I guess I will try to get into it.


Hey

A couple of days ago I started with Flash and ActionScript.
The reason why I am doing this is because I want to make games,
and Flash seems to be a good start.

Anyways, I tried coding around a little (was not hard because I already know
several coding languages like Python, PHP, Lua, JavaScript, C++... [altough I just know
the basics of C++]), but you know that is not really exciting and it's somewhat hard to
get started making anything because I don't know the possiblities.

On Google (and here, of course) I searched a guide, but all I found was
some tutorials "how to make a platform game" and such. That is not the thing I search,
because that wouldn't help me much.
I think a guide would be really nice, something with excercises and showing one up
what how to do something and so on. Or maybe many little tutorials
that can help you in any situation.

What I am basically trying to ask for is a guide or a few tutorials a beginner should start with.
I'm sorry if that is somehow a very common topic or so, but I didn't find relating topics with the search.
Maybe there should even be a tutorial section or so, but that lies in the hands of the admins and mods.

Response to: 3istee's Art Posted July 17th, 2012 in Art

At 7/17/12 11:47 AM, Tomsan wrote: Ha u downloaded a picture and added a filter in photoshop (or whatever). maybe added some lighting, but nothing else.

I should now, I do it to sometimes.

Nope.
The only thing that I've done with filters is the background in the first image.
Everything else is drawn by hand (with a graphic tablet).
As you can see on this image I have layers necessary.
On the very top there are the lines (or the colors I used in the first case),
and further down there are different layers seperated by color (or all small objects like
the combadge, the eyes and the mouth on one layer).
The layer above the color-layers with the arrows are shading-layers. That arrow means that
the content on this layer will only be visible on the content of the parent layer.
If you don't believe me it's not my problem.

3istee's Art

Response to: 3istee's Art Posted July 17th, 2012 in Art

At 7/17/12 11:26 AM, big-jonny-13 wrote: Painting over an actual image isn't going to teach you anything.

I don't wanted to learn by drawing these,
but I wanted to draw them :P

I could draw from scratch, and I mostly do this,
but I am not that good at linearts.
Maybe drawing the linearts of his hands helps me a little,
at least at drawing hands.
You have to know, even if you don't see lines in the images
I did them for both, kinda as help for coloring.

If you have any suggestion I could try that.

Response to: 3istee's Art Posted July 17th, 2012 in Art

Picard's "Wtf is this shit?!"

3istee's Art

Response to: 3istee's Art Posted July 17th, 2012 in Art

Internet Explorer is not a webbrowser, it's just called one.
I thought double-posting was not allowed because it is not in many other boards,
but I have not seen it in the rules here, so I guess I'll do it.

Picard's Facepalm

3istee's Art

Response to: 3istee's Art Posted July 17th, 2012 in Art

At 7/17/12 08:49 AM, M-Maher wrote:
At 7/17/12 08:30 AM, 3istee wrote: Hey,
bad news: HTML doesn't actually work here
Good news: this is your first post; welcome to newground's forums.

Yeah actually noticed that ^^
Sadly there isn't an edit option so can't correct that.
Altough this is was not my first post, thank you :P
Is there any way to include two images in one post?
Because uploading doesn't seem to work.

3istee's Art Posted July 17th, 2012 in Art

Hey,

some of the art I've made.

Picard's Facepalm
<img src="http://i.imgur.com/fHyi6.jpg" style="width: 720px">

Picard's "WTF is this shit?!"
<img src="http://i.imgur.com/tLicj.png" style="width: 720px">

Response to: Keyboard input stutters? (AS3) Posted July 16th, 2012 in Game Development

At 7/16/12 01:01 PM, milchreis wrote: Why do you work with frames?

I didn't want to, I suppose I misclicked.

Response to: Keyboard input stutters? (AS3) Posted July 16th, 2012 in Game Development

At 7/16/12 02:21 AM, milchreis wrote: The KEY_DOWN Event has this behavior and as you figured out already, that's to ease input.
But you decoupled it from that, by using KEY_DOWN and KEY_UP to set the speed.
The movement of the object is done in ENTER_FRAME which will be called continuously (no stuttering)

Yeah, I know, but flash thought I had released the key altough it was not the case.
As I said it was because I had the frames wrong.
So my problem is solved, at the moment I just try to make that movement smooth and
rotate the ship instead of moving it with the A and D keys.
But that's not the topic here.
Again thanks anyone.

Response to: Keyboard input stutters? (AS3) Posted July 15th, 2012 in Game Development

-_-
I am slightly pissed.
The problem was that the keyframe was after a few frames -_-
So obvious but you don't expect that to happen.

Thanks anyways all of you for your efforts.

Response to: Keyboard input stutters? (AS3) Posted July 15th, 2012 in Game Development

At 7/15/12 06:39 PM, XJ-47 wrote: import flash.events.Event;
import flash.events.KeyboardEvent;
import flash.geom.Point;

stage.addEventListener(KeyboardEvent.KEY_DOWN,key_down);
stage.addEventListener(KeyboardEvent.KEY_UP,key_up);
stage.addEventListener(Event.ENTER_FRAME,move);

var speed:Number = 10;
var velocity:Point;
velocity = new Point();

function move(e:Event):void {
ship.x += velocity.x;
ship.y += velocity.y;
}

function key_down(e:KeyboardEvent):void{
switch (e.keyCode)
{
case 87: velocity.y = -speed;break; //w
case 65: velocity.x = -speed;break; //a
case 83: velocity.y = +speed;break; //s
case 68: velocity.x = +speed;break; //d
}
}

function key_up(e:KeyboardEvent):void{
switch (e.keyCode)
{
case 87: velocity.y = 0;break; //w
case 65: velocity.x = 0;break; //a
case 83: velocity.y = 0;break; //s
case 68: velocity.x = 0;break; //d
}
}

I copied that code into a blank project (into frame 1) with one MovieClip on stage called "ship".
Works fine for me.

Yeah I think it's not a code-problem but something with flash.
I don't know, maybe I have set up Flash wrong, I just installed it.
Is there any settings I should apply?

Response to: Keyboard input stutters? (AS3) Posted July 15th, 2012 in Game Development

I got it from the trace() function.

Response to: Keyboard input stutters? (AS3) Posted July 15th, 2012 in Game Development

At 7/15/12 06:28 PM, XJ-47 wrote: You should do some debugging.

Add a trace command for when, for example, the W key is pressed and when it gets released.

The output should be:

*you press and hold W*
"W pressed!"
*pause*
"W pressed!"
"W pressed!"
"W pressed!"
...
*you release W*
"W released*

If the output is like that then your code should be working.

Sorry I ignored your first message,
I wanted to edit mine because you ninjad me (:P) but I didn't found the button.
Anyways, yes in previous debugging it said "true true true true false false false true true true...".

Response to: Keyboard input stutters? (AS3) Posted July 15th, 2012 in Game Development

At 7/15/12 06:20 PM, milchreis wrote:
At 7/15/12 05:53 PM, 3istee wrote: it still stutters :S
It shouldn't. How big is the delay?

You can see it yourself.
When you hold down a key (for example "a"),
it first only writes "a".
If you keep on holding it will continue writing "a"s.
a....aaaaa (...)
you know?

I think you are german (or your name is absolutely deceptive :P),
if you want to, you can write me an message and I will give you my skype name.

Response to: Keyboard input stutters? (AS3) Posted July 15th, 2012 in Game Development

it still stutters :S

import flash.events.Event;
import flash.events.KeyboardEvent;
import flash.geom.Point;

stage.addEventListener(KeyboardEvent.KEY_DOWN,key_down);
stage.addEventListener(KeyboardEvent.KEY_UP,key_up);
stage.addEventListener(Event.ENTER_FRAME,move);

var speed:Number = 10;
var velocity:Point;
velocity = new Point();

function move(e:Event):void {
	ship.x += velocity.x;
	ship.y += velocity.y;
}

function key_down(e:KeyboardEvent):void{
	switch (e.keyCode)
            {
                case 87: velocity.y = -speed;break; //w
				case 65: velocity.x = -speed;break; //a
                case 83: velocity.y = +speed;break; //s
                case 68: velocity.x = +speed;break; //d
            }
}

function key_up(e:KeyboardEvent):void{
	switch (e.keyCode)
            {
                case 87: velocity.y = 0;break; //w
				case 65: velocity.x = 0;break; //a
                case 83: velocity.y = 0;break; //s
                case 68: velocity.x = 0;break; //d
            }
}
Response to: Keyboard input stutters? (AS3) Posted July 15th, 2012 in Game Development

At 7/15/12 03:46 PM, milchreis wrote: Do not store the keys.

Instead, when a key is down, set a variable like "speed" to the desired value.
(the Point class would be handy as it stores the 2 dimensions of the speed vector)

Now within ENTER_FRAME, just apply the vector to the .x and .y property.

Could you suggest how to initialize that variable?
Because I am not sure.
I would do something like "ship.speed", but then again I am not sure how to define the data-type.


Hello,

I am a newbie with Flash and ActionScript,
and I have a problem, also I think it's a noob-problem, but whatever.

I tried making an symbol that moves around as I press W A S D,
that works with the help of XBigTK13X's tutorial, altough not entirely fine.
Because after I hold a key down (for example W) the object moves a little, then stops, and again continues moving, without that I have released the key.
I think this is that "letter spam protection" or such (don't know how it's called).
That has the same effect, when you hold "w" down, it will only type one w for the first time, but if you hold it a bit longer it will
continue typing w smoothly.
But that has nothing to do in game-controls.

Someone know how to disable it?

That's the code:

import flash.events.KeyboardEvent;

var keyArray:Array = new Array();
var i:Number;
for(i=0;i<222;i++){
keyArray.push([i]);
keyArray[i] = false;
}

stage.addEventListener(KeyboardEvent.KEY_DOWN,checkKeysDown);
stage.addEventListener(KeyboardEvent.KEY_UP,checkKeysUp);
stage.addEventListener(Event.ENTER_FRAME,move);

function move(e:Event):void {
	trace("W:" + isKeyDown(87))
	if (isKeyDown(87)) {		//w
		ship.y = ship.y - 10;
	} else if (isKeyDown(65)) {		//a
		ship.x = ship.x - 10;
	} else if (isKeyDown(83)) {		//s
		ship.y = ship.y + 10;
	} else if (isKeyDown(68)) {		//d
		ship.x = ship.x + 10;
	}
}

function checkKeysDown(event:KeyboardEvent):void{
keyArray[event.keyCode]=true;
}
function checkKeysUp(event:KeyboardEvent):void{
keyArray[event.keyCode]=false;
}
function isKeyDown(X){
return keyArray[X];
}