For example if im making a kamehameha script, and i want the player to hold down the G key to charge then when it reaches a number, it fires where the players mouse it looking at.

2 comments

0

You could make a loop that checks if the G key is still pressed and if so it increases a value by 1 or whatever you want, you could also create an equation that simulates the size of a potential sphere of energy based on value. If you took a try at it i might answer.

0

An easy way of doing this would just be to use the ContextActionService and bind the G key to a function that when G is pushed it starts counting up everyone once in awhile, and when G is released, it fires.