Games Achievements My Kong Sign In

Comments for Stencyl Tutorial 4: Mouse-Based Shooting

« Back to Stencyl Tutorial 4: Mouse-Based Shooting

snackman76

Jan. 02, 2012

Under rating threshold (show) my bullet is just weird looking i dont even see it on the screen. idk plz message me back threw pm and help me cause i rlly wanna become as good of a game maker as you

+ - !

(-1)

Developer response from Abigayl

I've replied to the PM. I highly advise coming to the livestream for one-on-one help. Even if I am not on, there are other regulars there who might be able to help out.

Abigayl

Dec. 17, 2011

Under rating threshold (show) I am curious at how many people come to these tutorials just to play the game at the end, using "2" to skip there. If you are one, please rate this comment up (else please don't :P). Thanks.

+ - !

(1)

Halagaz

Dec. 18, 2011

Under rating threshold (show) I hope it's not the last one! I've just need to study trigonometry a little bit (as well as English)) and I hope I'll make at least one stupid game) Oh, my mistake, I should say thanks first! Thanks a lot!!!

+ - !

(1)

Developer response from Abigayl

lol, you're welcome. I'm glad to be of help :). The fifth one will be the last one for a while. (I may do a second set focusing on platformers when SW2 comes out).

ZhaneEndrick

Dec. 17, 2011

Under rating threshold (show) Abigayl, thanks again for a wonderful tutorial. I think you are covering Stencyl at a really useful pace. I've been poking around the program for a few months, but have always run into problems figuring out how to do things. I'm beginning to understand the steps that need to be taken. Even though I'm not working on an 'avoider' game, this has helped me with what I am doing. Oh, and it has also reminded me that I'm a little rusty on my trig, need to crack open some old math books. I'm really enjoying this series and it is helping me a lot. I'll be eagerly awaiting your next tutorial.

+ - !

(0)

Developer response from Abigayl

Thanks Zhane :). The fifth tutorial will be my last for a while. I am glad to see that people can look past the idea of this being an avoider game and use the actual concepts to help them with their own games :)

aronzei

Dec. 17, 2011

Under rating threshold (show) I'm grasping more and more about Stencyl with every new tutorial. Thank you. :)

+ - !

(0)

Developer response from Abigayl

Glad to be of help :)

PaulisterGaming

Apr. 08, 2012

Under rating threshold (show) HELP! For some reason I can't fire the bullets!!

+ - !

(0)

Developer response from Abigayl

Are you sure you attached the behaviors? If you want, upload the game to Forge and send me a PM with its name and I'll take a look at it to see what's wrong.

qwertyuiopazs

Mar. 29, 2012

Under rating threshold (show) Oh, I accidently did create bullet at (x:x of self, y: x of self.) by the way the bullets weren't going where i clicked, they were going at what seemed to me as random places, and I just happened to click on two in a row and assumed wrong.

+ - !

(0)

Developer response from Abigayl

So it works now? If so, good (couldn't really tell by your post)

alobalo1

Dec. 18, 2011

Under rating threshold (show) can you make it in a bigger screen?

+ - !

(0)

Developer response from Abigayl

Unfortunately, I cannot. I am almost up to the maximum horizontal size allowed and to make the pictures bigger would increase the file size quite a bit :(

DemonOfMist

Apr. 20, 2015

Under rating threshold (show) Re-did this tutorial. I had to refresh some of the trigonometry by referring to some websites, but I got it. Thanks!

+ - !

(0)

Developer response from 0_Tuo_0

I'm glad you got it down :)

DemonOfMist

Apr. 13, 2015

Under rating threshold (show) I had to tweak the collision part (the colliding shape detector) a bit to make it work due to updates. It works, but hope it will not cause problems when I finish tutorial 4.

+ - !

(0)

Developer response from 0_Tuo_0

You have me curious: what tweaks did you need to do?

DemonOfMist

Apr. 13, 2015

Under rating threshold (show) Found it! You can check width in Stencyl under collision tab of the actor.

+ - !

(0)

Developer response from 0_Tuo_0

If you are constantly changing the size, a draw text and/or print command can work in real time too ;)

DemonOfMist

Apr. 13, 2015

Under rating threshold (show) Do we always have to open paint to find out what is the width of our actor? Is there a way to check in Stencyl?

+ - !

(0)

Developer response from 0_Tuo_0

There are many ways, including the collision tab (I often create a new box collision and then cancel as it will show the actual size if I've adjusted the collision box currently on it).

DemonOfMist

Apr. 13, 2015

Under rating threshold (show) Trigonometry... I learned that stuff so long ago wondering why I ever did, but now it comes down to this....

+ - !

(0)

Developer response from 0_Tuo_0

Aye, I use my programming as an example for students who don't see the value in trig ;).

123kenny10

Dec. 04, 2013

Under rating threshold (show) you know the bullet look just like the one i made LOL

+ - !

(0)

Developer response from Abigayl

It's a circle. There really is not a lot of varieties for circles... :P

Toope00

Dec. 04, 2013

Under rating threshold (show) What if the bullet comes from the back of the actor and hits the actor itself?

+ - !

(0)

Developer response from Abigayl

If you have the collision groups set so that the bullet's group doesn't collide with the player's group, then it shouldn't be an issue.

sirmoo2

Oct. 23, 2013

Under rating threshold (show) my actor does not seem to point towards my mouse. i have tried everything. PLEASE HELP!!!

+ - !

(0)

Developer response from Abigayl

If your scene is bigger than your screen, you'll have to add the x/y of the camera to the x/y of the mouse for it work properly. If you post a screenshot of the coding (or upload the game to StencylForge and make it public), I can try to look at it to see what's wrong.

Abigayl

Oct. 17, 2013

Under rating threshold (show) SirMoo: In the Actor -> Position palette, there is a "point self to X degrees". That is what I am referring to.

+ - !

(0)

sirmoo2

Oct. 16, 2013

Under rating threshold (show) I do not see the "face direction" code block you had mentioned earlier. PLEASE HELP!!!!

+ - !

(0)

Abigayl

Oct. 16, 2013

Under rating threshold (show) Hello Sirmoo, For whatever reason, I can't seem to create a response, but yes you can. In the Actor palette, there is a "face direction" code and you can use the same coding for the shooting for that direction (you will likely have to add or subtract 90 though to make it work).

+ - !

(0)

sirmoo2

Oct. 16, 2013

Under rating threshold (show) Hey there! Is there any way i can have my player face the mouse constantly, like turn and face the mouse no mater where it is on the screen? I keep trying but still have no luck :(

+ - !

(0)

roflmoqkz2

Oct. 10, 2013

Under rating threshold (show) For some reason my game crashes when the enemy dies. I did exactley what you did and it doesnt work.

+ - !

(0)

Developer response from Abigayl

Can you describe the crash? Is there an error that pops up? If you want, upload the file to StencylForge (don't forget to make it public) and let me know the name, and I'll take a look at it for you. There's not much I can do without seeing the file itself.

BalsG

Aug. 23, 2013

Under rating threshold (show) Yeah, i can shoot(and move) in only half of image, instead if all image, sorry for my english.

+ - !

(0)

Developer response from Abigayl

Perhaps upload your game to StencylForge, make it public, and tell me the name of it. I'm still not understanding the issue, so seeing it directly might be better.

BalsG

Aug. 23, 2013

Under rating threshold (show) Question is: Why? (see in previous mesage the problem) and how to make to be the full image?

+ - !

(0)

Developer response from Abigayl

I don't understand. Why do you mean "can't shoot in all image"? That was the question.

BalsG

Aug. 23, 2013

Under rating threshold (show) another question: if i shoot i cant shoot in all image (just in left and up the right and down is only a half of distance

+ - !

(0)

Developer response from Abigayl

Question: What is the question?

BalsG

Aug. 23, 2013

Under rating threshold (show) hey! i watch all the tut, did all right but when the bullet colide with the enemy just push them away, don't kill em.

+ - !

(0)

Developer response from Abigayl

Make sure you have the kill codes in the collisions and that the behaviors are each attached to the actors.

young1000

Aug. 04, 2013

Under rating threshold (show) can i make my own?

+ - !

(0)

Developer response from Abigayl

That's the entire point of this series! :D (Do be sure to start at part one though; the site for Stencyl is www.stencyl.com)

goldpig3718

Aug. 03, 2013

Under rating threshold (show) this game is cool

+ - !

(0)

Developer response from Abigayl

It's even cooler when you make it yourself! :)

letsgome

Dec. 27, 2012

Under rating threshold (show) never mind, figured it out

+ - !

(0)

Developer response from Abigayl

Glad you got it working :)

letsgome

Dec. 27, 2012

Under rating threshold (show) how do u submit the scores?

+ - !

(0)

PhaserRave

Dec. 26, 2012

Under rating threshold (show) Yes. It was really odd. It just didn't work when the same code was in a behavior, and only worked when it was in the actor's event tab. :s

+ - !

(0)

Developer response from Abigayl

If you want to, upload it to StencylForge, and I'll take a look at it.

PhaserRave

Dec. 16, 2012

Under rating threshold (show) Yes, I had.

+ - !

(0)

Developer response from Abigayl

Are you sure that you have the bullet as a sensor collision and that its collision group doesn't hit the player's group?

PhaserRave

Dec. 15, 2012

Under rating threshold (show) Might be a double post, but it doesn't seem to have posted my first comment. Somehow when I include the code as a behavior, my actor won't shoot anything, but works when I include the code in the actor's event thing.

+ - !

(0)

Developer response from Abigayl

Did you remember to attach the behavior to the actor? That is the issue with behaviors: it's easy to forget to "attach to actor" (the big green button in the upper-right).

Glock243

Aug. 13, 2012

Under rating threshold (show) How could I make the bullet shoot in the direction the player is facing?

+ - !

(0)

Developer response from Abigayl

In the Actor -> Position palette, you can find the "direction self is facing" code. Then, you can use that as the angle for the bullets (please note, you may have to add/subtract 90 from it to make it work correctly, depending on how you setup your actors).

Sagalink

Aug. 10, 2012

Under rating threshold (show) I'll probably never really make a video game but knowing alot about how they are made really shows me how much people work on them, which helps me respect even weaker games. I CANNOT believe it is so complicated, but if you practice, you can even make a totorial on making a game, huh? :)

+ - !

(0)

Developer response from Abigayl

Aye, for the most part, you can estimate at least one hour of programming per MINUTE of gameplay (varies a lot depending on if you are making a mini-game or a full-fledged game).

monsterjamp

Mar. 24, 2012

Under rating threshold (show) I actually figured out what i was doing wrong after i posted that comment. I have one problem (sadly) the bullets wont disappear when they hit an actor and the actor does not die by the bullet. I don't know what i am doing wrong. please Help Again.

+ - !

(0)

Developer response from Abigayl

Are the two colliding? Check your Game Center -> Collision Groups and make sure the button between the enemies and the bullets is green, not blue.

monsterjamp

Mar. 23, 2012

Under rating threshold (show) I followed your tutorial but then realized you were shooting from a previously made actor. I want to know how to shoot directly where your mouse is (out of nowhere). Please help.

+ - !

(0)

Developer response from Abigayl

If you want to shoot directly at the mouse, no movement (like in a shooting game), just use the "x of mouse" and "y of mouse" coding alone, without any subtraction. If you want to shoot things directly, then just use "if mouse was released on self" coding in the actor's code itself. Does that make sense?

boxheadwinner

Mar. 17, 2012

Under rating threshold (show) Ah. I had forgotten a part. My bad.

+ - !

(0)

Developer response from Abigayl

Glad ya figured it out :)

boxheadwinner

Mar. 17, 2012

Under rating threshold (show) My bullets won't shoot all around, only in one direction.

+ - !

(0)

Developer response from Abigayl

In your Game Center, check your collision groups and make sure your bullets aren't colliding with your player, which could cause them to bounce off, making them go in only one direction.

screaminpoet

Mar. 05, 2012

Under rating threshold (show) hi abigayl, thanks for the tuts! they were great, easy to follow and entertaining. here is my version, because i use a laptop i opted for a space button gun, with a spray of +-10px. i also made enemys face the direction they are flying which i though made it look so much better. i plan on creating stages and more weapons via powerups. thanks again http://www.kongregate.com/games/screaminpoet/stencyl-tutorial-shooter

+ - !

(0)

Developer response from Abigayl

Not half bad :)

ChazDragoon

Jan. 14, 2012

Under rating threshold (show) Hm..strange...after finishing this tutorial i can't even test my game..it just goes through the motions then...dead. Nothing. I restarted Stencyl but still nothing...hmmm

+ - !

(0)

jelmerdokkum

Jan. 13, 2012

Under rating threshold (show) I followed the tutorial but when i click in my game i just start to turn around and the bullets just stay at the player Do you know how this is possible? Love your tutorials! Like the idea how you make them

+ - !

(0)

Developer response from Abigayl

Are you sure you attached the bullet movement behavior to the bullets? If you didn't, they will just stay at your player. If you did, then please screenshot it and send me a link. My livestream (livestream.com/poweredbyflowers) is the best way to reach me for one-on-one help.

iroald

Jan. 09, 2012

Under rating threshold (show) Really helpful tutorials, maybe I'll finally get off my lazy ass and start making a game myself. One thing: the information on how to switch pages in the tutorial is on the 2nd page. Not very practical. I know I can always scroll down a bit for the controls, but I think it's my OCD talking now :P

+ - !

(0)

Developer response from Abigayl

I don't know how to put the controls on the first page without destroying the welcome message... perhaps instead of the Stencyl logo... would need some feedback if that sounds good though. I tried to use the simplest advance controls, ones I would hit personally.

warshon

Dec. 25, 2011

Under rating threshold (show) Maybe in the future, you can explain how to make power ups and bonuses. (ex. one that gives you more damage for a few seconds and one that gives you a few hundred points)

+ - !

(0)

Developer response from Abigayl

Alright, will try to add that in #5 :) EDIT: Added in Tutorial 5: http://www.kongregate.com/games/Abigayl/stencyl-tutorial-5-music-powerups-more

CritterForge11

Mar. 01, 2012

Under rating threshold (show) Guys, just learn how to code in a REAL language, coding a game like this in a real language would take far less more time than it would in Stencyl.

+ - !

(-1)

Developer response from Abigayl

It's not all about speed (and Stencyl is fast) but rather easing into programming. As I have said many times before, if you know how to code in AS3 or another language, you should probably stick to that. Stencyl is a good stepping stone though. You don't go straight to Calculus without first learning about functions ;)

monsterjamp

Mar. 24, 2012

Under rating threshold (show) Yes the collision groups are okay. The bullet hits what i want it to hit but it does not seem to follow the "Kill Self" command.

+ - !

(1)

Developer response from Abigayl

Can you screenshot the coding and send me the link? Or, better, could you upload it to the Forge and tell me the name, and I'll take a look at it?

Darksaber530

Apr. 25, 2013

Under rating threshold (show) Thanks! Now I can complete my game. I modified the healthbar script so that when the enemy's health is low, the healthbar changes color. Thanks again for the help!

+ - !

(-1)

Developer response from Abigayl

You're welcome. I'm happy to help :).

klimtkiller

Mar. 10, 2013

Under rating threshold (show) high score: 1711 :)

+ - !

(-1)

Developer response from Abigayl

Congrats :)

dreeseaw

Apr. 08, 2012

Under rating threshold (show) I followed your exact shooting coding but it will always fire just 1 bullet

+ - !

(-1)

Developer response from Abigayl

Are you sure you used a "do every" instead of "do after" code? If you want, upload the game to Forge and send me a PM with its name and I'll take a look at it to see what's wrong.

qwertyuiopazs

Mar. 28, 2012

Under rating threshold (show) Also, I can't find out why, but my bullets are spawning from where my mouse clicked, not the guy.

+ - !

(-1)

Developer response from Abigayl

If you want, take a screenshot of the code and send me the link (or just upload the game to StencylForge and send me the title). You likely have some correct coding in the wrong spot, such as putting the bullet creation in a scene behavior instead of the player behavior.

ChazDragoon

Jan. 14, 2012

Under rating threshold (show) ah i see..so, for the sake of example: things like character/enemy attributes (hp, strength, etc.) are better used to local attributes while things like..say.. Day/Night time should be a global?

+ - !

(-1)

Developer response from Abigayl

Correct.

  • add a comment
Developers Players Support YouTube TikTok X (Twitter) LinkedIn
Join the conversation Join Discord
Terms Privacy Code of Conduct
© 2024 Kongregate