Valentine90 Posted February 10, 2013 Author Share Posted February 10, 2013 **Sorry my english**When you attack a Resource (eg a tree) is not observed the attack time of the gun, causing the player to attack more than it should.**Open Server****1-** In **modPlayer**, search for:``` If Map(GetPlayerMap(index)).Tile(x, y).Type = TILE_TYPE_RESOURCE Then```**2-** ABOVE add:``` ' Check attack timerIf GetPlayerEquipment(index, Weapon) > 0 ThenIf GetTickCount < TempPlayer(index).AttackTimer + Item(GetPlayerEquipment(index, Weapon)).Speed Then Exit SubElseIf GetTickCount < TempPlayer(index).AttackTimer + 1000 Then Exit SubEnd If```**3 -** After of:``` ' send message if it existsIf Len(Trim$(Resource(Resource_index).EmptyMessage)) > 0 ThenSendActionMsg GetPlayerMap(index), Trim$(Resource(Resource_index).EmptyMessage), BrightRed, 1, (GetPlayerX(index) * 32), (GetPlayerY(index) * 32)End IfEnd If```**4 -** Add:``` ' Reset attack timerTempPlayer(index).AttackTimer = GetTickCount```**Credits:**Valentine Link to comment Share on other sites More sharing options...
Alerd Posted February 10, 2013 Share Posted February 10, 2013 Is it good that I added?![](http://img145.imageshack.us/img145/2926/90179940.png) Link to comment Share on other sites More sharing options...
lucasandrelimabarro Posted February 10, 2013 Share Posted February 10, 2013 @Valentine Thanks, this is very good and i was added. Vlw man kk@adiif1 Yes, this is good, the play can't attack the resource with a speed more than speed of the equipped weapon, this prevent hack and bugs. Don't forgot to add the 4 part of tutorial becouse this is necessary and a bug will caused if miss this part. Link to comment Share on other sites More sharing options...
Tic Tac 2 Posted April 26, 2015 Share Posted April 26, 2015 Awesome!! This prevents speedhacking on resources :) :)Is there a way to do this to player movement? So people can't speedhack movement Link to comment Share on other sites More sharing options...
Tic Tac 2 Posted April 29, 2015 Share Posted April 29, 2015 People can still speedhack bows, how do you fix this? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now