Under rating threshold (hideshow)
Couldn't get the source files to download, but eventually found that if I right clicked the link, and selected Open in New Window, it would let me download them. Maybe this'll work for someone else as well.
Under rating threshold (hideshow)
omg im so stupid my problem was that i hadnt gotten to the part that i had thought i had (i thought i had programmed the missiles to collide, i hadn't)
Under rating threshold (hideshow)
Alright I have an issue. I don't know if it's because im using CS4 or what but my collision() isn't correctly identifying with the enemy ships... I did it just like it says to and nothing hapens when they collide. I even changed the instance of my ship to Hero (=P) to see if that would wor and nothing. I suppose it's a code error but the game still runs with no compiler errors. Please help.
Under rating threshold (hideshow)
jeez this stuff is complicated... i feel like theres a simpler way to do this, but i guess its not the most efficiant or nearly as awesome. great tutorial! its easy to do, harder to understand
Under rating threshold (hideshow)
ok i gotta problem when my enemyships enter the stage it's fine and when they collide with my ship they explode, fine but when i shoot my missiles at them it only explodes them 1/10th of the time? help someone
Under rating threshold (hideshow)
It doesn't. "ship" refers to one instance of the "Ship" class. Each instance has its own copy of any properties defined on the class. So to answer willzi's original question: you use "_root.ship.enemies" because you want the enemies array that is part of that specific instance. If you tried to use "_root.Ship.enemies" it wouldn't work because the array isn't static, and if you made it work, that would mean you could only have one copy of the array in the whole applet. (That's probably ok for enemies, but imagine, say, health or position being the same for all ships.)
Under rating threshold (hideshow)
I got it. But I'm sure that if it wasn't clear to me, I'm probably not the only one. So for clarification, ship refers to everything above the background.
Under rating threshold (hideshow)
Why do you use _root.ship (instead of _root.Ship) to refer to the enemies array on page 10? The array is part of the class, not the movieclip =/
Under rating threshold (hideshow)
Select the movie clip from the .fla tab ( the one that shows your ship and the background) and on the right hand panel where your library is will also be a tab for properties. Click it and at the very top of the panel to the right of the pic of a gear is the box where you change the instance name.
Under rating threshold (hideshow)
Roydsey,
My advice would be to go back to Tutorial 4 and make sure you did all of the enemy ship script right. That is where you will get delays between ships.
Under rating threshold (hideshow)
Can't find explosion file anywhere? Downloaded source file but it said something about unexpected format error. Is there another way to get it?
Under rating threshold (hideshow)
Ive done everything ok and finished this tutorial but when i click test movie get 100's of ships coming on at once does anyone know how to fix
Under rating threshold (hideshow)
got all of the code input into my game but when i run it the enemy's spawn in the upper left corner and dont move...any one know whats wrong?
Under rating threshold (hideshow)
i have been following this
all works fine except for a couple things
ships dont blow up or dissapear when shot (neither mine nor enemies) although the bullets disappear and also my explosion appears in the corner
Under rating threshold (hideshow)
@theshow720: I'm very new to all this myself, but this is how I get to the linkage properties: Right click (or Ctrl click) the item you want in the library. Click Properties. Check the box Export for ActionScript if it is unchecked. Enter your Identifier and Class. :) Hope that was what you were talking about, and that I helped. Good luck.
Under rating threshold (hideshow)
Nevermind the below comment, I figured it out.
However, I can't select "Linkage" from the context menu when I "control-click" "explosion" from the Library, it doesn't show up.
Does anyone know why this is happening or another way around this? Perhaps because I'm using CS4?
Under rating threshold (hideshow)
Wow, I'm an idiot. :D I had my EnemyShip registered wrong, so none of the coordinates worked. I couldn't figure out why I had to compensate in the code (they'd originally appear and disappear in the wrong spots, and the explosions would bizarrely be offset by a few hundred pixels). Then I realized what it must be, and fixed it. Scary. Eep.
Under rating threshold (hideshow)
i added the explode function and now my ship is broken i cant fly it or shoot and its not detecting any problems. help?
Under rating threshold (hideshow)
the collision detecting is working fine, but now when the ship collides with an enemy all enemies explode. any suggestions to fix this?
Under rating threshold (hideshow)
I'm in a helpful mood today.
@Pacres: I had the same problem, no clue what the actual problem is, I'd suggest just calling it something else, like playership
@MCC900 Add a hittest between the enemy and the player's ship in the enemies onEnterFrame function. not sure of the exact synatax, but it's something like "this.hitTest(playershipname)"
Under rating threshold (hideshow)
This shootorial is excellent! I'm finally starting to understaned how flash games work and how to make them. Now I'm having a small problem with the collision hero-enemy, when the first enemy ship collides with the hero, the explosion animation is constantly being created while both ships are touching, and the enemy keeps going to the left instead of being destroyed. But after that, the collision works fine with all the other ships.
HELP! What am I doing wrong?
Under rating threshold (hideshow)
If you want the source file, message me and I will give you a download link. open up the FLA, go to Library, copy the explosion file, open your FLA, and paste. It will automatically put it in your library too.
Under rating threshold (hideshow)
For people having trouble downlaoding it, I got it, and uploaded it to my media fire.
http://www.mediafire.com/download.php?gyxfnljnfne
open up the FLA, go to Library, copy the explosion file, open your FLA, and paste. It will automatically put it in your library too.
Under rating threshold (hideshow)
heres the strange way I managed to get the source files. I'm running vista 32bit btw. i chose ope n in new window, and it closed. I did it again, and IE became unresponsive. i closed it, reopened IE, and chose restore session, and then the download file worked.