Home  | Login  | Register  | Help  | Play 

RE: Flash Q&A thread 2 ** checked everyday

 
Logged in as: Guest
  Printable Version
All Forums >> [Gaming Community] >> [Legends and Lore] >> Artists of Legend >> Art Academy >> RE: Flash Q&A thread 2 ** checked everyday
Page 13 of 24«<1112131415>»
Forum Login
Message << Older Topic   Newer Topic >>
4/18/2006 23:36:03   
mathus the seconth
Member

i am making a color pad. i need to know how you change the color of the line when you click a box.

http://img153.imageshack.us/my.php?image=colorpad6hz.swf
AQ  Post #: 301
4/19/2006 9:04:43   
independence quiad!!
Member

mathus if your interested do you want a clear button
AQ DF  Post #: 302
4/19/2006 14:32:57   
mathus the seconth
Member

what??? clear for what?
AQ  Post #: 303
4/19/2006 17:13:32   
flsg
Member

lol, clear the image of cours
anyway, here's the code:
on(release){
  _root.clear()
}


lol that was easy
the clear() function clear everything on the field did by the program(API)
AQ  Post #: 304
4/20/2006 0:54:50   
independence quiad!!
Member

flsg that dont work
this is the coding i have used
on (release) {
if(_root.canvas_mc == Number(_root.canvas_mc)){
unloadMovieNum(_root.canvas_mc);
} else {
_root.canvas_mc.unloadMovie();
}
}

and change canvas_mc to the name your movie clips name is this is my example http://img128.imageshack.us/my.php?image=drawingwithmouse3gc.swf

< Message edited by independence quiad!! -- 4/20/2006 1:05:12 >
AQ DF  Post #: 305
4/20/2006 5:00:46   
Zoltan
Member

Ummm, yeah.... dont ask... http://haze.voodoolabs.net/darts.swf
Post #: 306
4/20/2006 5:31:48   
independence quiad!!
Member

upgraded my pen thingy http://img163.imageshack.us/my.php?image=drawingwithmousemultibutton4gb.swf

< Message edited by independence quiad!! -- 4/20/2006 5:40:17 >
AQ DF  Post #: 307
4/20/2006 6:26:56   
Valgaera
Member


quote:

ORIGINAL: Zoltan

Ummm, yeah.... dont ask... http://haze.voodoolabs.net/darts.swf


AHAHAHAHA!!! I just laughed ms a,ss off. Thats wicked! Bookmarked!!
AQ  Post #: 308
4/20/2006 6:34:35   
Nickwright
Creative!


I just did it too....Nice Zoltan...
AQ DF MQ AQW Epic  Post #: 309
4/20/2006 6:39:55   
james001
Member
 

Thanks flsg.
Post #: 310
4/20/2006 13:17:16   
Darklord517
Member

quote:

ORIGINAL: Zoltan

Ummm, yeah.... dont ask... http://haze.voodoolabs.net/darts.swf


Woot. Got him in the Eye. Oh yes now the temple.
AQ DF  Post #: 311
4/21/2006 18:22:28   
mathus the seconth
Member

i made a cool movie with PURE actionscript.

put this on the first frame:

this.createEmptyMovieClip("line", 1);
this.createEmptyMovieClip("box1", 2);
this.createEmptyMovieClip("box2", 3);
box1.lineStyle(1, 0x00000);
box1.beginFill(0xFF0000);
box1.moveTo(0, 0);
box1.lineTo(0, 20);
box1.lineTo(20, 20);
box1.lineTo(20, 0);
box1.moveTo(0, 0);
box1._x = 100;
box1._y = 200;
box1.onPress = function() {
	this.startDrag();
};
box1.onRelease = box1.onReleaseOutside=function () {
	this.stopDrag();
};
box2.lineStyle(1, 0x00000);
box2.beginFill(0x0099FF);
box2.moveTo(0, 0);
box2.lineTo(0, 20);
box2.lineTo(20, 20);
box2.lineTo(20, 0);
box2.moveTo(0, 0);
box2._x = 400;
box2._y = 200;
box2.onPress = function() {
	this.startDrag();
};
box2.onRelease = box2.onReleaseOutside=function () {
	this.stopDrag();
};
this.onMouseMove = function() {
	line.clear();
	line.lineStyle(1, 0x000000);
	line.moveTo(box1._x+10, box1._y+10);
	line.lineTo(box2._x+10, box2._y+10);
	updateAfterEvent();
};


test your movie and then drag and drop the boxes!!! fun, fun, fun!!!
AQ  Post #: 312
4/21/2006 18:31:35   
somebody621
Member

Ummm...Instead of writing all that code, why not just use a for loop? Also, why do you use a moveTo in some places and _x and _y in other places? It's kinda confusing when you look after it when you come back to the code. I also don't see the reason to have to use moveTo twice for each box. It's unefficient. But nice try at something that's pure actionscript.

Edit: I'm thinking of doing something like that sometime, but much more extensive and complicated.

< Message edited by somebody621 -- 4/21/2006 18:32:27 >
Post #: 313
4/21/2006 19:24:39   
mathus the seconth
Member

whats a loop? and the moveTo for each box thing... i copied the box1 code and switched 1 with 2.(yes im that lazy)

< Message edited by mathus the seconth -- 4/21/2006 19:27:51 >
AQ  Post #: 314
4/21/2006 22:04:22   
flsg
Member

whaaaaat?!?! mathus the seconth: it's cool, but the code isn't......clean enough
you don't need to use box1 or box2 everytimes, you could use with(), like this:
with(_root.box1){
  lineTo(...)
  lineTo(...)
  //bla bla bla...everything with _root.box1
}

with() let you use the same target more than once, because when you draw a thing, you always draw the same(is that clear? )
if you use box1.lineTo() 1000 times, it would be hard to correct that after if you want to change the target

< Message edited by flsg -- 4/21/2006 22:07:48 >
AQ  Post #: 315
4/21/2006 22:08:00   
Valgaera
Member

I edited it for a 3rd and 4th square. I tried to get another line to connect the 1st and the 4th, but i couldnt figure it out
AQ  Post #: 316
4/22/2006 15:31:24   
flsg
Member

can someone tell me if they know a multiuser server named SmartFox Server?
I want to try it, but I don't know if it's good. I want to buy Unity(a popular multiuser server) but it's too expentive(800$)
and don't tell me to buy Comm Server(Macromedia Flash Media Server), it cost 4500$
edit: nevermind, SFS cost 2800 CAD
man, I'm a loser. I'm can't program a multiuser application in Java, and I don't have enough money to buy one...

< Message edited by flsg -- 4/22/2006 15:35:29 >
AQ  Post #: 317
4/22/2006 15:34:46   
somebody621
Member

There's a demo version that's exactly the same but only supports 20 users.
Post #: 318
4/23/2006 10:14:14   
flsg
Member

somebody do you know why ElectroServer, Comm Server or SmartFox Server cost so much and Unity is so cheap?

_____________________________

My flash gallery
my game thread

flsg, proud old member of AQ(still playing :O)
AQ  Post #: 319
4/23/2006 10:18:27   
swenn
Member

Alright i hae an actionscript problem:
I use this code: http://www.kirupa.com/developer/mx/random_motionMX.htm
to make some text ransdom moving and to do that i need to make a ON handler so all that works now my problem is:
i want to make the random movement things(cone's in the tutorial) to be a button that you can click but i can;t combine two on handlers how do i fix this?
*btw: i use flash 8
AQ MQ  Post #: 320
4/23/2006 11:37:50   
somebody621
Member

I would seriously learn how the code works before you use it (learn a little more about OOP, like it's strength's, etc.). It will really help. And yes, you can combine two on handlers.
flsg:probably the amount of users that can go on at a time. I believe for SFS Lite, it's 2000 for unlimited.
Also, consider the amount of features already programmed in.
Post #: 321
4/23/2006 12:13:47   
swenn
Member

How do i combine two ON handlers?? if i know that my problem is fixed edit: wat is OOP?
AQ MQ  Post #: 322
4/23/2006 13:36:39   
flsg
Member

swenn: I suggest you to learn AS 2.0 really hard before use it on anything
here's a solution:
since we can create an empty function like this:
function (){}
in a event handler:
onKeyDown=function(){}
we could use a reference:
function myFunc(){
trace("hi")
}
_root.onKeyDown=myFunc
which means we could use:
mc1.onRelease=mc2.onRelease=myFunc

I think it's important to know the essential of a piece of code, why it works and how it works before using it in a real Flash movie
somebody: Unity with unlimited license cost only 739$ and SFS with unlimited license cost 2000$

< Message edited by flsg -- 4/23/2006 13:39:45 >


_____________________________

My flash gallery
my game thread

flsg, proud old member of AQ(still playing :O)
AQ  Post #: 323
4/23/2006 13:50:14   
swenn
Member

well do you have any tutorials? but i really need this script very soon so if someone could make it for me i would apriciate it really
AQ MQ  Post #: 324
4/23/2006 14:36:37   
flsg
Member

tutorials? Search on google, or buy some books
AQ  Post #: 325
Page:   <<   < prev  11 12 [13] 14 15   next >   >>
All Forums >> [Gaming Community] >> [Legends and Lore] >> Artists of Legend >> Art Academy >> RE: Flash Q&A thread 2 ** checked everyday
Page 13 of 24«<1112131415>»
Jump to:






Icon Legend
New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts




Forum Content Copyright © 2018 Artix Entertainment, LLC.

"AdventureQuest", "DragonFable", "MechQuest", "EpicDuel", "BattleOn.com", "AdventureQuest Worlds", "Artix Entertainment"
and all game character names are either trademarks or registered trademarks of Artix Entertainment, LLC. All rights are reserved.
PRIVACY POLICY


Forum Software © ASPPlayground.NET Advanced Edition