How would i make a car selection screen where the user is prompted to slect a car and once they select the car they want tot use it will appear in the game as the car they selected . Any flas would be much appretiated :)
Thanks In AdvancE :cool:
Printable View
How would i make a car selection screen where the user is prompted to slect a car and once they select the car they want tot use it will appear in the game as the car they selected . Any flas would be much appretiated :)
Thanks In AdvancE :cool:
Not Actual Code (Dotn Copy and Paste):
On a Choose Car Button youd have something like this:
OnRelease {
carselected = "redcar"
}
And on the racing keyframe of ur game, put something like this on a frame action:
If (carselected = "redcar") {
_root.car.gotoandStop("redcar");
}
///Make the gotoandStop whatever you want, but "redcar" would be the frame inside the car movie clip which is the actual drawing of the red car
lol, I fell 210% retarded.... When I read this, I thought he was talking about color selection, so I spent about 20-30 minutes working this out real quick... (remember kids, always put parenthesis around your work or I can guarantee you, you will get an error with flash telling you need a semi colon.....)
Well, I get it done, and realize it isn't what he wanted, but I'll post it anyways, cause I'm sure someone might be able to use it :)
-genesis f5
-go here: http://www21.brinkster.com/flashhelper/changecolor.html
(full source available from site, to allow direct linking)
Son of a POTaTO!!!!!!!!!!!!!!!!
for the love of cabbage... I try to make this nice example... all is working fine in mx... save it in flash 5... and whadda you know.. the piece of celery won't work. I can't believe this..
well, all I can say is I will have it fixed and up tomorrow..
Time to go to bed here.....
-genesis f5
if youve used the new colour stuff in mx it wont work in f5
What new colour stuff in MX? I don't know of any. The color object was introduced in F5.
setColorTransform?
think its mx, not sure though... it was an educated guess on why it wouldnt work :D
Nope, it's F5.
i tried what you said BLDesign but it didnt seem to work do you have a fla that i can look at ?
Appearently it is only mx, well, not the RGB Transform...
I used -
Code:nc=new Color(this)
nc.setRGB("0x"+_root.colorrr)
Soooooooo....
go here, to see the updated swf....
http://www21.brinkster.com/flashhelper/changecolor.html
-genesis f5
Hooligan I didn't make an .fla but I guess I can for you.
Its an MX fla. Hope thats ok.
Also, you can drive the car around too... the source is my gift to you :)
SWF: http://www27.brinkster.com/cargame/colorselect.swf
FLA: http://www27.brinkster.com/cargame/colorselect.fla
Have to copy and paste :( Sorry about that.
Did nobody see my example?
lol, genesis f5-
hey BLDesign how do i make it so in frame one i choose the color and in frame 2 the color of the car will be the color selected ?
hey Genesis F5 good example but i cant run it through f5 cos its done in mx right ?
have you set the RGB or use the mx way ?
yeah, sorry about that...
-genesis f5
My .fla example will work with multiple frames.
you mean setTransform? And it is most certainly F5. Othervise it's funny that I used a Flash MX function in Flash 5! ;)Quote:
setColorTransform?
setRGB will make the whole car one solid color. no room for details there.
i don't know if this will help but it uses a container to hold all the logic for the object and then it uses attachMovie() to select the image.
http://www.nlc.net.au/~oceana/games/container.swf
http://www.nlc.net.au/~oceana/games/container.fla
hope this helps
BlinkOk
Yeah i can do that but what i dont understand is just say i have 4 buttons
redcar
bluecar
greencar
enter
so when i press redcar it sets carselected to blue
carselected = "blue";
and then after that when you press enter it goes to frame 2 where the car will be red so what i want to know is how to carry varibles over to the next frame ?
http://www.nlc.net.au/~oceana/games/setTransform1.swf
http://www.nlc.net.au/~oceana/games/setTransform1.fla
variables always exist accross frames. hope this helps
BlinkOk
Thanks Blink your always a big help thats kind of what i wanted but i dont want to change the rgb but instaed attach the red car mc to the container mc but i think i figured it out :)
Thank You!Quote:
Originally posted by Mirandir
you mean setTransform? And it is most certainly F5. Othervise it's funny that I used a Flash MX function in Flash 5! ;)Quote:
setColorTransform?
setRGB will make the whole car one solid color. no room for details there.
i stand correctedQuote:
Originally posted by Mirandir
you mean setTransform? And it is most certainly F5. Othervise it's funny that I used a Flash MX function in Flash 5! ;)Quote:
setColorTransform?
setRGB will make the whole car one solid color. no room for details there.
Wasn't my .fla of any help? It seems exactly what you are asking for.
I don't understand this code
_root.colorrr = "0000CC";
because theres nothing named colorrr in the movie
It isn't anywhere... but stored in frame one, and recalled by the "paint" movie clip within the car movie clip.
_root.colorrr is just a variable stored within the _root directory, so it can be acessed from all frames.
-genesis f5