The Daily Click ::. Forums ::. Klik Coding Help ::. Audio problem
 

Post Reply  Post Oekaki 
 

Posted By Message

TheGoldMiner88



Registered
  18/05/2018 11:35:50
Points
  14
17th June, 2018 at 17/06/2018 19:25:51 -

when my character jumps it makes a sound.
Problem is, when the player is in the air, and player clicks jump button (Lshift) it will make a jumping sound again.
My code looks like this:
When Shift is pressedlay sample


 
n/a

TheGoldMiner88



Registered
  18/05/2018 11:35:50
Points
  14
17th June, 2018 at 17/06/2018 19:27:58 -

When shift is pressed:
play sample

sorry i didnt know that would happen.

 
n/a

AndyUK

Mascot Maniac

Registered
  01/08/2002
Points
  14586

Game of the Week WinnerSecond GOTW AwardHas Donated, Thank You!VIP Member
17th June, 2018 at 17/06/2018 21:06:51 -

It's doing excactly what you told it to do.

You need a condition where it only plays the sound if the player isnt already jumping.
So, as an example

When Shift is pressed
+
When player jumping animation is NOT playing



play sample

 
.
   

Post Reply



 



Advertisement

Worth A Click