• Add Friend
Age / Gender:
24, Male
Location not disclosed
All Stats >

User Statshot

Community Stats
Level 5 Game Developer
Normal Whistle
Ranked as Civilian

Contact Info / Websites

Latest News

AS3 Console

2012-05-05 03:52:20 by ASSHOLELA

Hi guys,
I've made an actionscript console for you to control your flash games directly! (kinda like the cheat console that pops up when you press some key in half Life or halo)
You type your actionscript commands into the line, and you can tell your game objects to do whatever functions, set whatever property on your game objects or even create new instances of objects!
This makes your debugging a whole lot easier

Here, download and try out this swf to see what I mean: d702e843324e6f3f9aff

In the swf file, there is a Console. Press the ` key to make it appear or dissapear.
Type your commands into the line below the top rectangle. where it says "root::". press enter to execute.

Below the console, there is a box. You can experiment with it by typing: x = someNumber; = someDegrees;;, someY);
etc etc...

You can also spawn stickMen by typing:
root.manX = new Man('name'); e.g "jon";
root.addChild(root.manX); will add the man to the stage.

Now you can make your man do stuff by typing:
root.manX. jump(); //man jumps
root.manX.kill();//kills the man
root.manX.say ('whatever you want');// makes the man wave and say whatever you want
you can also create a variable and store 'whatever you want anywhere', and then have your man say the variable.
root.manX.sayStuff = 'whatever you want';
var manSays = 'whatever you want'

Finally, if you are game, you can try typing this:
root.manX.addEventListener(Event.ENTER_FRAME,roo t.manX.walk);

and the man will walk left every frame!

You can also access the Man class and perform its static functions:
Man.listMen();//traces to the console the names of the men you have created
Man.allJump();//causes all the men on the stage to jump

Try whatever you want and let me know what you think!

You can download the fla file for the console here CS5.5: e35ff5f1f74c06da574b

You can download the code that makes the console work here: b65241470ec1e8a598d0.

Its in a folder called Pasv2. The folder has the documentation telling what you can do with the code files.basically, the AS files allow you to execute and load Actionscript variables from a string containing actionScript, and you can also save your game objects into actionScript as well!

To include the files into your project, paste the folder into your project folder and then type :
import Pasv2.* into your game code. And follow the instructions in the documentation.


Recent Game Medals

SECRET MEDAL 10 Points Unlock this medal to see it's details. Medal Stats.

Total Medals Earned: 1 (From 1 different game.)