i have a player character that has 2 attack types, a single punch and a combo attack. i want it that when the player is not near any objects/ or enemy AI to play the single punch. and if the player is in attacking distance , to play the combo attack.
the problem is that I dont know how to switch the attacks since they are both bound to the 'J' key. ive tried to change the attack when the player is in the objects 'body_entered_area' but it doesnt work.
I cant find any tutorials either online . thanks
i setup a basic player move and attack script and then added a function with combo . then i tried to initialise the combo when the player enters the enemys area body . but without success