badspacebar / sdk

6 stars 3 forks source link

Check if hero is winding up #29

Closed 69sinisterblade69 closed 10 months ago

69sinisterblade69 commented 10 months ago

Is it possible to check if player/hero is winding up? As far as I checked you can't do it with orb.core.can_attack() orb.core.can_action() (and other currently documented features) because you technically still can action while winding up, it's just that doing so will cancel your aa.

badspacebar commented 10 months ago

I think orb.core.can_attack() is enough you can also check orb.core.cur_attack_start_client/ orb.core.cur_attack_start_server and player:attackDelay() player:attackCastDelay(64)

69sinisterblade69 commented 10 months ago

As I've said in previous message, orb.core.can_attack() wouldn't work because it still returns true even when attacking will cancel your previous aa. Thankfully other dev have told me about orb.core.is_winding_up_attack(), which as far as I tested worked exactly how I wanted, though I could probably achieve the same result with the method you mentioned.

badspacebar commented 10 months ago

more docs added now, please let me know if there is something missing