Driving Game (Please Help)
Hi All!
I am making a first attempt at a driving game - but am having a bit of trouble with the screens.
I want the car to be able to drive off one screen and start on another without the user having to click anything. The car is controlled with the arrow keys.
Does anyone have any ideas?
FlashKit > Flash Help > Flash General Help
Posted on: 09-08-2003, 03:06 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Driving Game
I'm in the process of writing a driving game (the kind where you can see the whole track from above and have small cars). I've got as far as creating the car and controlling it's movement. This bit is cool. It even has a little sideways drift if it corners too fast. I just wanted to ask if anyone had any thoughts on the best way to limit the movement of the car such that it stays within the confines of a track. This is more of a philosophical question than a nitty gritty technical question. What would your approach be? I don't think hitTest is going to be the answer....
HELP Driving Game
Hi!
I'm trying to create a micro machines style driving game! This basically means a top down game where the background moves rather than the car which stays fixed in the centre. Something like this:
http://www.gamelinks.com/game.php?linkid=3658
The most annoying thing is that I know I should be able to make it work! It really is doing my head in!
So any help would be great!
Cheers
Driving Game - HELP
I'm trying to build a top down driving game (like oldschool gta). Ive built the map generator, so it attaches and removes tiles as you scroll around the map.
However, i cant seem to add the car to the map and make the car push the map around correctly...
anyone know of any good tutorials on this sort of thing??
m
Driving Game
I am building a drivin game where the car stays still & the actual background (iem the track moves). When the car hits the sides of the background it should bounce back. Anyone got any scripts lying around for this control engine?
A Driving Game IA
Hello,
First of all, please scuse my english
I want to make a driving car game like MicroMachines, the move of the car sems possible to do, but How to manage the move of the other cars from computer on several circuits ?
Thx a lot to give me idéa
Driving Game - Links
Hi,
I am creating a driving game using an ariel view and snippets of code from the tutorials section. I have the car sorted and have two seperate backgrounds on seperate slides, as you can see from the source file I attached. I would like to know how to link the slides so that as the car drives off the right of the first slide, it appears on the second slide relative to where it left the first one.
Thanks for any help you may be able to offer.
A. Scripting Driving Game
Hey,
I know how to rotate an object and how to move an object, but I can't figure out how to get the rotation to correspond with the motion. In the past I've just used 8 positions and made up the x and y differences from some equation I made up. But I can't figure out how to do it with 360 positions. Any ideas?
Art Based Driving Game - Help
I am making a small game with a drivable vehicle the view is from above and I've made it with a tile based method, like Zelda. What I need to do is turn it into a game where you can drive around and the background moves with the vehicle like an art based rpg.
I've got the code for the vehicle and accurate hit tests and consequences all I need is the code to work.
Theres an art based rpg here: http://www.gotoandplay.it/_articles...a60632455fff19f but I don't know which code where should go where in my game from the example.
The art based source file is here: http://www.gotoandplay.it/_articles..._zelda_v1.3.zip
If anyone would be so kind to help me because this is quite urgent.
Driving Car Game Turning
Hi guys,
I am producing a car driving game (plan view). Forward accelerate, backwards brake/reverse, left and right is turn.
My problem is i am setting the left and right buttons to rotate the vehicle. Is this the best way to do it. I have tried putting the rotation point in the centre of the vehicle and in the middle of the back axle but it still doesnt look right.
I have seen the Jeep on:
http://www.infinitumdesign.com
and it doesnt seem to be as slick as this does.
Any help appreciated. Thanks in advance.
[F8] Driving Game Boundaries
I am trying to make a driving game. For this I need to make a track as a boundary (to test at the moment it is only a square)
The car sometimes can escape out of it tho
Could you please look at the flash and suggest what I have done wrong
Thanxx, Joel
Need Driving Car Engine For Great Game
Im doing a super good game and I need a racing engine for some scenes of the game. The game is so advance that I dont have time to program one myself.
It should be a "overhead" and be about the quality of www.illogicz.com
I can show you some screens from the game later.
EDIT** I forgot to say it's must be Macromedia Flash engine
Looking For A Little Help With Multiple Sounds For A Driving Game That I Made.
Looking for a little help with multiple sounds for a driving game that I made.
Any help would be appreciated.
I made a driving game and it has a few sounds that can and often do actuate
simultaneously.
I use the “new sound(); attachSound("attchAccell");” method
to load the sounds and then call them “if(_level0.movie, hittest” etc. when certain events occur. like hitting a sign or a curb.
This works and works well but only for one sound at a time.
As soon as I connect the sound variable to another hittest action, none of the sounds work at all.
Does anyone have suggestions or example on how to use multiple
sounds for a game type environment?
Help Making Driving Movements In As3 Flash Game
I want to create a game in which the hero is an overhead car view.
I want the car to be a movie-clip called from the .as file, with turning, reverse, gas, and friction.
I found ---this--- which is perfect but i do not know how to create something like this for as3, for that tutorial link is for as2.
Thank you for any help,
Joey
Help Making Driving Movements In As3 Flash Game
I want to create a game in which the hero is an overhead car view.
I want the car to be a movie-clip called from the .as file, with turning, reverse, gas, and friction.
I found ---this--- which is perfect but i do not know how to create something like this for as3, for that tutorial link is for as2.
Thank you for any help,
Joey
URGENT Driving Game Like Art Based RPG URGENT
I am making a small game with a drivable vehicle the view is from above and I've made it with a tile based method, like Zelda. What I need to do is turn it into a game where you can drive around and the background moves with the vehicle like an art based rpg.
I've got the code for the vehicle and accurate hit tests and consequences all I need is the code to work.
Theres an art based rpg here: http://www.gotoandplay.it/_articles/...60632455fff19f but I don't know which code where should go where in my game from the example.
The art based source file is here: http://www.gotoandplay.it/_articles/...zelda_v1.3.zip
The code for the vehicle for convenience:
ActionScript Code:
onClipEvent (enterFrame) { // make the car go forward if (Key.isDown(Key.UP)) { speed += 1; } // make the car go backwards if (Key.isDown(Key.DOWN)) { speed -= 1; } // tells the car to slow down after the speed of 20 if (Math.abs(speed)>20) { speed *= .7; } // you can change the rotation of the car to your desire if (Key.isDown(Key.LEFT)) { _rotation -= 15; } if (Key.isDown(Key.RIGHT)) { _rotation += 15; } // here is where the hittest is for the boundary speed *= .98; x = Math.sin(_rotation*(Math.PI/180))*speed; y = Math.cos(_rotation*(Math.PI/180))*speed*-1; if (!_root.land.hitTest(_x+x, _y+y, true)) { _x += x; _y += y; } else { speed *= -.6; }}
URGENT Driving Game Like Art Based RPG URGENT
I am making a small game with a drivable vehicle the view is from above and I've made it with a tile based method, like Zelda. What I need to do is turn it into a game where you can drive around and the background moves with the vehicle like an art based rpg.
I've got the code for the vehicle and accurate hit tests and consequences all I need is the code to work.
Theres an art based rpg here: http://www.gotoandplay.it/_articles/...60632455fff19f but I don't know which code where should go where in my game from the example.
The art based source file is here: http://www.gotoandplay.it/_articles/...zelda_v1.3.zip
The code for the vehicle for convenience:
ActionScript Code:
onClipEvent (enterFrame) { // make the car go forward if (Key.isDown(Key.UP)) { speed += 1; } // make the car go backwards if (Key.isDown(Key.DOWN)) { speed -= 1; } // tells the car to slow down after the speed of 20 if (Math.abs(speed)>20) { speed *= .7; } // you can change the rotation of the car to your desire if (Key.isDown(Key.LEFT)) { _rotation -= 15; } if (Key.isDown(Key.RIGHT)) { _rotation += 15; } // here is where the hittest is for the boundary speed *= .98; x = Math.sin(_rotation*(Math.PI/180))*speed; y = Math.cos(_rotation*(Math.PI/180))*speed*-1; if (!_root.land.hitTest(_x+x, _y+y, true)) { _x += x; _y += y; } else { speed *= -.6; }}
Driving Al The Way To....
Everybody who drives a car (Even if it just sometimes) knows what is looks like when you are behind the wheel and looking ahead through the window.
The road is passing by, so are building,three's and other cars.
This is exactly what I would like to make in flash.
But I got no idea how let the road move that it seems to pass by.
Hopefully someone can help me to start.
Thnx,
Jonnekke
Driving Al The Way To.....
Everybody who drives a car (Even if it just sometimes) knows what is looks like when you are behind the wheel and looking ahead through the window.
The road is passing by, so are building,three's and other cars.
This is exactly what I would like to make in flash.
But I got no idea how let the road move that it seems to pass by.
Hopefully someone can help me to start.
Thnx,
Jonnekke
Driving
ok i have a car, and i want to make it so that increases in speed as i hold down forward until a certain point, i also want to do the same thing with the wheels rotation.
i heard of something called xSpeed, but i dont know if thats in fla 5.
Driving Car...:)
I want to make an easy animation of a car driving foreward on the road like on the picture attatched.. Does anyone know any hints/tricks about a good way to do this? Or maybe someone knows about something similar that I can watch on the web for inspiration?
Driving Me Nuts
I have a problem.
In my movie I have another movie loaded into _level1. In _level1 I have a menu that I want to pop-up when someone "hits" a certain spot in that same level. I had previously tried an invisible button, but for some reason couldn't get it to work. So then I tried to use hitTest. Still didn't work. This is what I have...
In an AS layer on a frame...
startDrag(_level1.drag,true);
stop();
On my MC instance "drag"...
onClipEvent(enterFrame){
if(_level1.hit.htiTest(_level1.drag._x,_level1.dra g._y,true)==true){
_level1.tab1.play();
}else{
stop();
}
}
What I believe should happen is that when the _level1 AS frame is entered, my MC instance "drag" should start being dragged. When my MC instance "drag" hits with a rectangle MC instance "hit", that should cause my MC instance "tab1" to play from frame 1. Unfortunately nothing happens!
Can anyone tell me what I am doing wrong?
Thanks
dalara-rian
This Is Driving Me Nuts
centred pop ups
when i put this action on my buttons in my flash intro page to open a new window
on (release) {
getURL ("javascriptpenNewWindow('http://www.essextails.com/text_documents/home.html','Home','height=400,width=650,top='+((sc reen.height/2)-(" 400 "))+',left='+((screen.width/2)-(" 650"))+'toolbar=no,scrollbars=yes')");
}
it dont work and the debugger comes back with this error
movie, Layer=homebutton, Frame=78: Line 2: ')' or ',' expected
getURL ("javascriptpenNewWindow('http://www.essextails.com/text_documents/home.html','Home','height=400,width=650,top='+((sc reen.height/2)-(" 400 "))+',left='+((screen.width/2)-(" 650"))+'toolbar=no,scrollbars=yes')");
i am not that hot with actionscript and i am not sure if i have filled in the parameters right but most of all i cant see where the errors are
heeeelp
This Is Driving Me Crazy.........
I've got a menu bar in a movie clip which reveals on an invisible button. No problem so far.
When the menu comes up the movie stops, so that the user can click on a button in the menu.
However I want to move the movie on (and hide the menu) if the mouse moves beyond a certain point. I've checked my x coords and if the mouse moves beyond 10 on the x axis I want the action to be gotoandplay at a label called close.
I've tried:-
if (_root._xmouse > 10) {
_root.gotoAndPlay ("close")
}
and I've tried various combinations of _root, what am I doing wrong , it's doing my head in !!!!!!
PDF Loading Driving Me Mad Help
I am creating a small movie which allows the user to select a product then the movie loads a PDF file. I at first used Geturl to do this and it was sucessful. The directory stucture is this.
CDRoot
CDRootpdf
CDRootpdfProducts
all the pdfs are in the products dirctory and the get url was typed in as:
on (release) {
getURL ("pdf/Products/productX.pdf");
}
now this worked until I changed a few things and had to recreate the buttons. Now the stupid thing keeps trying to load http://pdf/products/productX.pdf. I don't know what else to do other than beat the hell out of the PC so for the sake of my humble PC help.
Many thanks James
Help.... Please It's Driving Me Crazy
I am so new to Flash. I have a class project that I in such need of help. I have a home page with four navigation buttons. Each button will go to a new scene and display an animation that I made in class. No problem so far. I got the buttons to go to each scene. The problem is when I open my animation file, I cannot find out the correct way to place the separate animation on each separate scene. I have tried copy frames, paste frames. I have tried to make each animation a mc. My guided paths go haywire. Can someone please... please help me. This project is due Thursday and I am so confused.
Thanks
Driving Me Crazy
Hello-
It's a mess, but trying to change a onClipEvent to gotoAndPlay instead of getURL. I'm using MX...
Action Scripting in Question below-
onClipEvent (mouseDown)
{
for (var j = 0; j < _parent.num_menu_items; j++)
{
if (_parent["item" + j].item_bg.hitTest (_parent._parent._xmouse, _parent._parent._ymouse, true))
{
getURL (_parent.urls[j],_parent.url_opening_style);
}
}
}
Thank you for any input. See attached file.
Help This Is Driving Me Nuts....
any help greatly appreciated!
When surfing my site, a strange thing seems to happen. After a short while (a couple of minutes) the site starts playing from the beginning of my timeline as if it is being refreshed or something. It can happen from anywhere in my site (my site is all pretty much on one timeline).
weird!
any ideas?????
if you want to check it out....
lupavision.net
Ok.....this Is Driving Me Crazy
I have a 10 empty mc lined up horizontally, for loading thumbnail images, which in turn will scroll horizontally. I'm trying to load all 10 images dynamically using XML
My question is ,how do i tell XML to load the thumbnail images into each mc? Can someone pleas help or point in the right directtion?
Thanks for all help,
MIKRO
This Is Driving Me Nuts
I keep running into this problem when embedding movies with functions inside container movies. What I have is a straightforward form to mail setup [FK tutorial] with basic validation on submission. The whole thing works fine when viewed on its own from the server [and locally] but breaks down completely once viewed from the container movie. I have tried addressing the paths to the functions absolutely and relatively, commenting out code etc yet it still refuses to run correctly.. I realise the problem could be anywhere, but any pointers on how to start troubleshooting would be helpful.
Fonts Are Driving Me Mad
When I publish my swf movie and watch it on another computer there are some fonts that are changed. The thing is that in the computer where I watch the finished work I don't have the type of font that I used on the flash movie, but why is flash doing this? I don't remember that on flash 5 there was this kind of problem. Is there a way to fix this or the only way would be that the "user" downloads and installs the type of font that I used.
by the way the type of font is Westminster and yes, I already converted to symbol the text with the problem.
Driving Onto Another Frame
anyone know how to do this? i cant figure it out. something to do with...
code: onClipEvent (enterFrame) {
if (this._x> 800) {
this._x = -50;
}
}
onClipEvent (enterFrame) {
if (this._y> 600) {
this._y = -50;
}
}
onClipEvent (enterFrame) {
if (this._x <-50) {
this._x = 800;
}
}
onClipEvent (enterFrame) {
if (this._y <-50) {
this._y = 600;
}
}
This Is Driving Me Nuts
Hey everyone,
I'm still kind of a newbie; getting used to Flash has been a wild experience. Trying to get my first project finished but can't seem to get around this "bug". (Of course, it's probably not!)
What I'm trying to do is very simple: create a motion tween based on text involving position, rotation, and skewing.
I've created a simple test file (attached) to recreate the problem I'm having. When I play it on the stage (by pressing enter), the animation looks fine. When I publish it, or try to preview publish (ctrl + enter) I get junk.
Any ideas? I can't move forward until I get past this! Pls!
Thanks,
Shahid
This Is Driving Me Nuts...
I have what I thought is a simple enough bit of code. I do a loadVar to a remote site and its hangs on me. One piece of code will work, another piece will lock up. AND they are the same code!
Is there something unique about timing I need to understand with loadVar if loadVar is calling on another server?
Thanks
Christopher
Driving Myself CRaZy?
Okay, I'm making a website where when a link is clicked I use a loadMovie command to load a SWF into a MC of the main website called "holder" (cuz it "holds" the MCs). So, for example, if someone clicks the "contact" link, then "contact.swf" is loaded into the MC called "holder"....
That being said, my problem is with the preloaders of the SWFs that go into the "holder" MC. While the main site's SWF is very small, some of the SWFS being loaded into the "holder" MC are not (one is 250kb, cuz it's design portfoilo work). I cannot get the loaded SWFs preloaders to work - they keep functioning as though they're reading the getBytesLoaded and getBytesTotal of the main website's SWF (so a SWF that's like 250 kb has a preloader that only works for the 15 kb of the main site - then it just sits there and waits on a blank screen until the loaded SWF is done loading)....
I've tried "this.getBytesLoaded" and "_root.getBytesLoaded" and "_root.holder.getByetsLoaded" - what am I doing wrong?!?....
Driving Directions Help.
I'm trying to make a flash form that when the user enters there address and zip etc. it will link to a yahoo maps or mapquest and get driving directions to my address. I'm having troubles can anyone help or have any ideas? Thanks in advance,
Driving Problem Please Help
right, i'm making a GTA 1 type game, with a birds eye view of a car the player can control. ive sorted out the car bit, but i want the background to scroll when the car drives. if you know what i mean. so when the car moves 3/4 the way up the screen the background starts scrolling up,and down and sideways etc.
i have no script so far atall so anything would help.
thanx.thefestivelemon
Driving Problem Please Help
please help somebody!!!! i have a game with an arial view of a car and map. this is my code at the moment....
onClipEvent (enterFrame) {
_root.speed = speed;
_root.speedness = Number(speed)*2;
_root.speedness -= _root.speedness%1;
if (_root.speedness<1) {
_root.speedness = 1;
}
if (Key.isDown(Key.DOWN)) {
speed += 2;
}
if (Key.isDown(Key.UP)) {
speed -= 1;
}
if (Math.abs(speed)>20) {
speed *= .7;
}
if (Key.isDown(Key.LEFT)) {
_rotation -= 14;
}
if (Key.isDown(Key.RIGHT)) {
_rotation += 14;
}
speed *= .98;
x = Math.sin(_rotation*(Math.PI/180))*speed;
y = Math.cos(_rotation*(Math.PI/180))*speed*-1;
if (!_root.map.hitTest(_x+x, _y+y, true)) {
_x += x;
_y += y;
} else {
speed *= -.6;
}
}
the speed is ok it displays it fine. the hittest(); with the map is also ok, im just having trouble making the map scroll as you move around it. please help.
ta.mike.
Swf Offset And It's Driving Me Mad...
I must be missing something here. My swf is 286X190 in size and I've inserted it into a table that is also 286X190. However, when the page loads, the swf resizes itself so that it's slightly skewed. Go here to see the page:
http://www.solartanthru.com/test2/header.htm
Any ideas?
This Is Driving Me Insane
I have a movie I am trying to do a preloader for but nothing is working..no matter what I do..nothing will play until everything is loaded.. I put a new scene in before my main scene and just typed a number..but that won't even show up until the entire movie is loaded...everything works fine once the movie is loaded... what are some possible reasons for the file doing this. Shouldn't scene 1 play and load before scene 2(I took out the preloader script just to check and same thing..the m,ovie doesn't start until everything is loaded) I need some suggestions before I pull out all of my hair
thanks,
Jeff
This Is Driving Me Crazy
good afternoon everyone!
i have been working on and off with this file. it is links for a school district website. i have 3 of the 4 links working, but cant get the link entitled "technology services" to work properly. the text keeps popping up instead of sliding down... grrr... can someone take a look and tell me where i have made my mistake?
thanks a ga-zillion!
Driving Me Nuts
Any help gratefully appreciated on this as the deadline is 8am tomorrow GMT
FlashMX 2004
I have a movie developed and it works fine when on its own. http://www.spoiltchild.com/new/davis.swf
However when loaded into another movie at level10 as it will be, it doesnt work. http://www.spoiltchild.com/new/holder.swf
Any ideas?
.fla is here: http://www.spoiltchild.com/new/davis.fla
I realy appreciate any help on this.
This Is Driving Me Crazy
Get this...
I have a movieclip in a project, that I want to change the colour of (dynamically).
Now... when run within my project.fla it doesnt work - but if I copy the frame with its actions and paste it into another file it works fine!!!!
this is even weirder.... if I delete ALL the frames and layers and ALL the library instances from my project.fla and repaste my frame with its actions it STILL doesnt work!!!! (the exact same frame and actions that works in other files)
these things are sent to test us - but this is doin' mi heed in!! :-)
Ive attached the fla (which works) if anybody could shed some light on this it would be MUCH appreciated
Help Me Please...driving Me Crazy
HELP!!
Flash version MX
Here is the problem. I've created a dynamic drop down menu that will be the navigation structure for a website. Everything works like a charm except for one major problem: everytime a link is pushed it pops open a new ("_blank") window.
It might be something simple.
Check out the source code. You'll need to be familiar with actionscripting to answer this question.
Thanks so much guys
NEEDS HELP!!
Driving Me Crazy
I have a movie clip that I can drag around the screen. When I let it go, it falls to the bottom. The problem I'm having is that it does not wait for me to let up on the mouse before the gravity pulls it down. Here is the code I am using:
onClipEvent(enterFrame) {
if(this._y < 620) {
this._y += 15;}
if(this._y > 600) {
this.gotoAndStop(2);
this._x += 5; }
if(this._y > 640) {
this._y = 640;}
if(this._x > 479){
this.gotoAndStop(1);}
if(this._x > 480){
this._x = 480;}
if(this._x < 0){
this._x = 0;}
}
onClipEvent(mouseDown) {
this.gotoAndStop(1);
if(this.hitTest(_root._xmouse, _root._ymouse)) {
this.startDrag(true);
}
}
onClipEvent(mouseUp) {
this.stopDrag();
}
I think I'm just putting something in the wrong order or something, but it is driving me insaine. If someone could help me out, I could put thier name in my movie, which will be on www.newgrounds.com...
Please Help, This Is Driving Me Nuts
Hello, I am new to programming in flash, if you get as far as viewing my code then you will probably agree Any how, I am having difficulty getting my drag and drop application to operate correctly. When I select a new piece from the drop down menu a previousley placed piece will vanish. I have a feeling that it is connected to the duplicateMovieClip function. I am also very sure that the hide piece on load procedure isn't the cause as this bug was ocurring before I implemented it.
Anyhows, the app(in its current early build) and the source is available here :-
http://fs1080.tripod.com/snowparkdesigner/
Any help would be very greatly accepted.
This Is Driving Me Crazy
here a simple problem I have movieClip in the library, with a dynamic text field. I set the linkage of the movie clip and set the character options for fonts. I use this code and I can't get the text field to populate.
trace("name "+_global.video_array[0]); shows Bob Joyce in out put field which is correct, why doesn't work?
Code:
_root.attachMovie("Video_cover", "vCover", getNextHighestDepth());
_root.vCover._x = 264;
_root.vCover._y = 378;
trace("name "+_global.video_array[0]);
_root.vCover.v_text.text = _global.video_array[0]);
_root.vCover.v_text.autoSize = true;
Please Help Me This Is Driving Me Crazy
okay, I have been doing flash for a while now but one thing that i have not been able to get working for me is transitions beween movie clips. I know how to do fade between them but i would like to have motion instead. I need the whole movie clip to load out (with some sort of tweening) before the next clip loads in (with some sort of tweening).
example:
if you were to click on button one, there would be a preloader, some sort of motion and then the movie would stop.
Once you clicked on another button, the current movie would do some sort of motion loading out and then the next movie would load, with a preloader and some sort of motion.
I would like to do this with 5 to 7 buttons.
I just cant figure out how to make it work to that if you click on button 3 and button 1 is loaded, how button 1 will unload and load button 2 but not button 4?
I assume that this will have have something to do with the script on my buttons. but if anyone could help that would be awesome.
if you need an example of what i would like to do, look at the link below. I would just like to know how to do this.
thanks.
http://www.mattpondpa.com/v1/mppa.html
p.s. i love this band and recommend everyone buying their records. in no way do i intend to still anything from their site.
Driving Me Crazy.
For nearly a fortnight now I've been trying to get a contact form to work. I've tried PHP and ASP. Scripts that work fine on other sites and servers just won't work. Members on FK have given me a lot of help, and sent files that they use successfully but just don't work. The site runs fine otherwise. I've just emailed the hosting company asking them to recheck things at their end. Can anyone think of anything that could be wrong there? Or may be a work around? If I hosted the contact form on my site and used the PHP script there should that work? Anything?
|