Hello, Does someone have any idea about how to put a script who read when a player use 10 mini heal magery spell so fast his client auto connection lost? I want to put this script because i cant cap uosteam's mini heal.

For example a player whose play using razor he take 5 seconds to do 10 mini heals and a player whose play using uosteam he take 3 secons to do 10 mini heals, because the player whose play using razor press the buton to mini heal 10 times and the player whose play using uosteam he let press the button.

Thank you all.
 
Just saying, if you kick the clients for being just a bit faster you might lose a part of your playerbase...
Did you test with the options/macro in the paperdoll to cast heal spells fast? this should work too.

Also about the "unfaire side", you should consider sending a warning message to the player and refuse to cast the spell instead of just "punching him in the face so he don't come back".

You could probably store a NON-serializing attribute on the playermobile to store "lastheal", and apply lastheal when successfully using the spell, if the lastheal is done too fast, (pm.lastHeal in the spell), send message & fizzles spell.

Would you need help to code that?
 
Thank you for answer, i saw the system i told on other shard and i liked it so much but this shard was closed and i cant talk to anyone admin from there. This is a good system because it can cap uosteam and easyuo super macros.

All help is welcome, i have thought to put it under the spell heal to make something like this system for example:
If you cast the spell "magic arrow" so fast hitting an enemy, the spell wont do any damage.
 
Last edited:
For the no damage part i think you could take a look at damage stacking on the spell system, it is similar. (ex, casting 10 explosions on someone = 1 explosion at the end)
 
I had an idea, i will explain it :)

Add 2 conditions on the spell heal script that if you cast 3 mini heal you cant cast other one without wait one second or cast another spell.
example:
1. cast 3 mini heal spell and wait 1 second, then you can cast other one again.
2. cast 3 mini heal spell and cast another spell, for example cast mini heal spell x3 and then cast clumsy.

Do you know how can i do it?
 
I'd go for two playermobile addition, a variable keeping the amount of heal you did, one for the lastheal time.

AND two static variable in the healspell.cs like so:
public static overcastWaitInterval = 1000;
public static overcastMaxCount = 3;

then you'll be able to compare the player's cast amount with the healspell static variable, if it's under, no problem: cast spell, and increment the heal count and the lastcast on the player.
if it's wrong, change the lastcast to the current time + one second (the overcastWaitInterval variable in healspell), and having a check if the lastcast is under or equal to the current time will re-enable casting and reset cast count to 1!

Those under are just pseudocodes as i have no idea about how the time format works on here.
Code:
if (pm.overcastLastCastTime <= time.now && pm.overcastCount < overcastMaxCount)
{
	++pm.overcastCount
 	pm.overcastLastCastTime = time.now
}
else
{
	pm.overcastCount = 0;
	pm.overcastLastCastTime = time.now + overcastWaitInterval
}
 
Its a good idea but is it no chance to add something on healspell.cs only? i have fear to edit playermobile.cs
 
Last edited:
You don't have to fear it as long as you do not serialize it and as long as you make documentation to where and what got added.
If you would like to have it in the spell script, you would have to store playermobiles in a list, which would be worse than adding a new property to playermobile.

New properties that you CANNOT edit, aka no [AccessLevel.GameMaster] stuffs over the new methods.
 
Back