Under rating threshold (hideshow)
um, if i hold down space, my laser will keep growing longer, and no matter what i type, it still fires way above where my ship is...help?
Under rating threshold (hideshow)
Well the joy and torture of programming is that if you make even the slighest mistake your whole program grinds to a halt. Takes a lot of patience to figure out where that one line or even letter is wrong. I spelled "missile" "missle" just once and took me a few minutes to notice the mistake and fix it.
Under rating threshold (hideshow)
got my error! but probably nor urs, I mistakedly (dunno how to spell this) inputted the code of page 5 in the MISSILE CLASS, didnt notice it was for the SHIP CLASS
Under rating threshold (hideshow)
hmh, Im trying to get a QUICK and SIMPLE way to get the missiles working
cuz I cant do it too, not even following other's advices, it just confuses me more
Under rating threshold (hideshow)
So I attempt to make my ship fire missiles but I somehow end up doing something so everything I did before that doesn't work. So much work gone to waste.
Under rating threshold (hideshow)
Mmmm, not bad. Not just that, its easy to adapt even for people who know very little about Actionscript (such as me). I've rigged my ship to fire a laser with the control button :P
Under rating threshold (hideshow)
It means you don't have a movieclip with the class as missile.when you convert it to symbol, go advanced otions click import for actionscripting, then make the identifier and class missile and it should work.
Under rating threshold (hideshow)
Look at the top, and make sure the class name is missile.
Same happened with me when i set "background" tp be pasted, it pasted as ship.
Under rating threshold (hideshow)
I've got this error saying, "The class 'Missile' needs to be defined in a file whose relative path is 'Missile.as'." and I've tried almost everything to fix it, can anybody help me?
Under rating threshold (hideshow)
Help? My compiler error =
**Error** C:\Documents and Settings\All Users\Documents\Marine.as: Line 28: This statement is not permitted in a class definition.
if( Key.isDown(Key.SPACE) )
Total ActionScript Errors: 1 Reported Errors: 1
Under rating threshold (hideshow)
Folks, make sure that when you copy/paste code from the shootorials that you must delete/overwrite functions from your program! You can't have two onEnterFrame functions in the same class for instance. CHECK YOUR COMPILER ERROR WINDOW!
Under rating threshold (hideshow)
I finally figured this crap out. Everyone having problems, just copy/paste this section to replace your problematic section. NOTE: This is not the full Ship Class, just the missle part of it! Good Luck!
-----------------------------------
if( Key.isDown(Key.SPACE) )
{
var missile = _root.attachMovie( "Missile" , "Missile" + _root.getNextHighestDepth() , _root.getNextHighestDepth() );
missile._x = _x + 50;
missile._y = _y + 2;
}
Under rating threshold (hideshow)
hey these are great tuorials but im having a bit of a problem with my missile. it comes out from the nose of my ship like i wanted BUT it doesnt move anywhere. im pretty sure i have the code right too.
Under rating threshold (hideshow)
D'oh! Stupid me!! Misspelt the Linkage Identifier as "Missle" LOL ... but now my missiles aren't going anywhere. They appear for a split second in front of my ship (smiley face ball thing) and then POOF gone.
Under rating threshold (hideshow)
Done code exactly as it says in tutorial, no spelling errors, lackof punctuation, etc, NOTHING noticably wrong, but when I press Spacebar, NOTHING happens. No compiling error,s just nothing. Ship moves as normal, as does the background. HELP. if(Key.isDown(Key.SPACE))
{
var missile = _root.attachMovie( "Missile","Missile" + _root.getNextHighestDepth(), _root.getNextHighestDepth());
missile._x = _x + 50;
missile._y = _y + 2;
}
Under rating threshold (hideshow)
I dont get it know why but my "missile" is firing from like an inch above my guy/"ship" I have exactly the same code though
-help would be appreciated
Under rating threshold (hideshow)
for some odd reason, the bullet fires if my left mouse button is pressed. ifif(Key.isDown(Key.SPACE && shootlimiter>8) ) has nothing to DO with the left mouse.
This is a great tutorial, none the less.
Under rating threshold (hideshow)
What the hell have I done...? I was up to Shootorial #5 and my missiles stopped working when I put collision detection in
Under rating threshold (hideshow)
none of my keydowns are working
i can't move or shoot but the background moves. i perfectly copied the code. maybe because i am using vista?
Under rating threshold (hideshow)
Virtualcrush try saveing all of the classes again nd make sure there in the same place. That error usualy means its not saved right.
Under rating threshold (hideshow)
This screwed me up a little bit in the beginning. remember that the code in you missile class isn't called unless the missile Movieclip is on stage.
Under rating threshold (hideshow)
To all people whose missiles APPEAR but they stand still no matter the speed values etc. The FILENAME has to be spellchecked too! I checked spelling from within the code and everything was ok. But then i saw my class file was saved as missile.as.. changing it to Missile.as made the missiles work. Such small change, such great results. =)
Under rating threshold (hideshow)
CHECK YOUR SPELLING.
Hey guys, after all that I found my problem. I deduced that flash was running the actual image through because they were popping up on screen when I hit the spacebar, so that problem had to have been the "Missile" class. I went to the missile and checked and checked and rechecked it. Finally I read the name of what I saved it. I named it Missle. Yep, I forgot the i. lol So check your spelling thouroughly guys.
Under rating threshold (hideshow)
Ah, I was wrong. My missiles are supposed to be moving. They are not moving, they are popping up in front of my ship and staying in place. I have looked at all my code to verify they are all correct. All of my classes are saved in the proper places to. So I can fire the missiles but they dont move. They are popping up in front of my ship and I am getting the error mentioned in my previos comment.
Any help would be appreciated.
Under rating threshold (hideshow)
Ok, I am up to part 7 of this tutorial. I have the missles working. Wherever my ship is the pop up right in front of it.
I realize I will make them move later.
The problem at this moment is, its all working yet I am still getting a compiler error.
Location:
Symbol+Missile, layer=black line, frame=1, line 1
Description
The class or interface 'Missile' could not be loaded.
Again, even though I am getting this I can still do the test it and move my ship around and fire missles. They stay where they are but I can fire them as you should here, just have an error at the same time.
Any help would be appreciated.
Under rating threshold (hideshow)
aah no idea what ive done wrong but now nothing works! had scrolling background etc working, tried adding missiles and its gone wrong :(
Under rating threshold (hideshow)
when i shoot my missile all that happens is that it stays there and doesn't move and i've checked spelling and everything that i've thought of and nothing works
Under rating threshold (hideshow)
Best tutorials ever, not just giving you scripts and telling you to add them to stuff, actually tells you what the scripts mean. If there is a problem with your game, make sure all the as files are saved and check the as on the tut and compare it to yours. 5/5