You don't have control over clientside stuff, it is trivial to edit the engine to spam weapon events even without editing csqc. that is a _massive_ loophole for cheats.
ok. Didn't know that.
additionally, sendevent is a reliable function. reliables require the previous reliable to have been acked before the next can be sent. this causes some massive latency issues. you do NOT want to have to update the position 10 times a second in your csqc, send that to ssqc over reliables with the aforementioned latency issues, then rebroadcast that to all the csqc modules. you're just getting a double-whammy on latency. its not feasable.
Didn't know that either. No, of course I don't want that
instead, send your event to ssqc using the input_frame stuff, have the ssqc respond to that based upon timings, and have all csqc modules updating the position. the server is the only authoritive entity, the only one that can really be trusted to not cheat.
CSQC_Input_Frame, huh? Well, never heard of it till now!
I'll try something on the net but on csqctest (my bible) it's unused. On Shpuld's Mobster Massacre there's some code. I'll dig it up, thanks.
Is this function a "csqc alter ego" of PlayerPostThink()?
self.attack_finished is a timer.
or did you never write any ssqc weapons code?
No, no.. we didn't understand each others!
I meant ... a timer for input, not for weapons!
Infact if, instead of weapon function I replaced ssqc code with
Code: Select all
void PlayerPostThink()
{
if (self.button0){
bprint("A\n");
}
}
It will print AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA as long I press mouse button.
On csqc it will print A. Stop. So it's not something related to my code but instead something related to how "button released" is managed in ssqc and csqc
menus, stuff where you really do need the raw events, stuff where you really do want to cancel those raw events to prevent the engine from acting on them.
whoa, really small breadcrumbs. Well this definately breaks my dreams with csqc.
I guess I'll do what everyone does: all the big part in ssqc, aided by small bits in csqc
Thanks Spike, vital as always your help