Announcement
Collapse
No announcement yet.
Slowing Players Down
Collapse
X
-
Mugwuffin repliedDo I put this piece of code into the UTPawn file and then add the functions in the UTWeap_LinkGun file or am I way off with that?
-
AdAstra repliedYou just add something like this
Code:function SetSlowEffect(float Duration, float Speed) { if(Speed < currentCustomTimeDilation) { CustomTimeDilation = Speed; // or you can just set the GroundSpeed and not bother with CustomTimeDilation currentCustomTimeDilation = Speed; bSpeedFXChanged = true; if(IsTimerActive('Timer_RestoreSpeedEffect')) ClearTimer('Timer_RestoreSpeedEffect'); SetTimer(Duration,false,'Timer_RestoreSpeedEffect'); } } function Timer_RestoreSpeedEffect() { CustomTimeDilation = 1.0; currentCustomTimeDilation = 1.0; bSpeedFXChanged = false; }
then call it when you do damage with the link gun
Leave a comment:
-
Mugwuffin started a topic Slowing Players DownSlowing Players Down
I have a mechanic I would like to use within the UDK I'm still getting to grips with all of it's features and I'm not all that great with coding if thats even whats required here. I would like to set the linkgun up so that when I use the alternate fire it slows the player or bot being fired at down, I would've used the search feature for a similar thread but I wasn't completely sure how to word it correctly and thought it would be quicker to just explain it here.
Anyways I assume this is possible and would just like to be pointed in the right direction if at all possible, Thanks for any help guys!
MugTags: None
Leave a comment: