Bad missiles flight with FLHook
-
Two months ago we installed FLhook on our server, and since then i’m constantly getting compliants from players about bad missiles flight.
They say that missiles fly jerky, unpredictable, and them flight shape is like lightning (not sure that i translated it correctly %)). When FLHook is disabled missiles fly normally at all.I tried to fix it by deleting hooks that ‘do nothing’, like this one```
void __stdcall SPObjUpdate(struct SSPObjUpdateInfo const &ui, unsigned int iClientID)
{
ISERVER_LOG();
ISERVER_LOGARG_UI(iClientID);Server.SPObjUpdate(ui, iClientID); try { } catch(...) { AddLog("Exception in %s", __FUNCTION__); }
}
But there was almost no effect… I really got stuck with that thing, dont know what it caused by and how to fix it... PS We're also running FLShell on our server (we ran it for some years).
-
This is not a bug introduced with FLHook, it is a timing bug in the flserver itself when serverload is very low.
Hmm… i’ve heard about that… I will make some more tests myself.
@Huor:may you try to describe what was your purpose by deleting hooks that are not used? Coz if they are not used why it should have negative influence on your missile tracking and flight?
‘Do nothing’ doesnt mean ‘not used’. They were used and called by FLserver, but while they don’t do anything they’re useless interrupts of thread flow. So i just commented them out until i’ll need this hooks.
-
It does appear on servers without FLHook.
Basically, it appears when the server spends almost no time in IServerImpl::ElapseTime.
You can see that behaviour on servers with a fast CPU and few or almost no active NPCs.Im pretty sure I tested it on a non-FLHook server to verify its not an FLHook problem.
/yes, I have put up a testserver:
193.192.58.150:2303
Password: 123
Name: TestBuy a cruise disruptor on Planet Malta, then glide by the docking ring and shoot on it, you will see the missile jittering effect. (if not, try again)
This server does not run any modifications, plain vanilla FL with no NPCs in Omicron Alpha.
-
…
Basically, it appears when the server spends almost no time in IServerImpl::ElapseTime.
You can see that behaviour on servers with a fast CPU and few or almost no active NPCs.…
What is this function call doing. Had a look into the source but couldnt find out anything…
-
Mischa did something similar on LC, he deleted basically every functionality that was affilated with the AntiBaseIdle, AntiCharMenuIdle, PingKick, PingKickFrame, LossKick & LossKickFrame -values in FLHook.ini… according to our measurements that improved the performance (since there were no more timers)… I think it wasn’t against missile jittering, but against “FLHook-lag”, but can’t remember… (you’ll see the comment “DIES IST ALLES DISABLED” in the FLHook.ini of the LC version)