★ wanayoo — archive 1999 https://github.com/alliedmodders/sourcemod/pull/614Nouvelle recherche | Portail wanayoo
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add A2S_Rules fix for CS:GO to CStrike extension. #614

Open
wants to merge 11 commits into
base: master
from
Open

Conversation

@psychonic
Copy link
Member

@psychonic psychonic commented May 27, 2017

This has been discussed a bit back and forth on IRC. I'm still not 100% sold on the idea, but here's what an implementation would look like. It's not too bad.

This would also fix our plugin stats for CS:GO.

@Drifter321
Copy link
Member

@Drifter321 Drifter321 commented May 27, 2017

Looks good to me. My only concern is the additional gamedata but its minimal and very easy to find.

@KyleSanderson
Copy link
Member

@KyleSanderson KyleSanderson commented May 27, 2017

This changes the max MTU size and when we talked about this when the situation was more "emotional", lets say, this is changing limits the game has defined. For whatever reason Valve still believes limiting the maximum MTU is a good idea, we should respect that (our positions have essentially inversed ;) ).

The solution at that time was to scrap querying servers, and instead do a periodic upload of server data back to an AM WebAPI to do stats. This is a lot more work as there's backend changes, but it was the path forward however many years ago we discussed this.

I'm flexible, I see some SW.ext code in there and that's totally fine, but we're not only changing their MTU on rules inquiries, but on all network traffic.

@psychonic
Copy link
Member Author

@psychonic psychonic commented May 27, 2017

but we're not only changing their MTU on rules inquiries, but on all network traffic.

That is not true.

This isn't changing it on all network traffic. The check only affects outbound, connectionless packets. No netchannel traffic is affected. Also, CS:GO is the only engine branch with this check, despite most of the other logic around it being identical to others.

@peace-maker
Copy link
Member

@peace-maker peace-maker commented May 27, 2017

You could add a hook on host_rules_show and only change the maxMTU and set the keyvalues on steam if it's enabled.

@psychonic
Copy link
Member Author

@psychonic psychonic commented May 27, 2017

I had considered that. There's just minimal gain if it isn't "fixed" to match all other games by default, still requiring manual action similar to how it does as-is.

@psychonic
Copy link
Member Author

@psychonic psychonic commented May 27, 2017

I just realized that I may have misunderstood what you were saying. You didn't mention changing the default, just not making the changes - doing anything, if it is disabled. That's a good idea!

@KyleSanderson
Copy link
Member

@KyleSanderson KyleSanderson commented Jun 13, 2017

Can we merge this?

@psychonic
Copy link
Member Author

@psychonic psychonic commented Jun 13, 2017

I want to do what @peace-maker suggested first, only having it enabled when host_rules_show is true, but haven't had the time yet.

@Drifter321
Copy link
Member

@Drifter321 Drifter321 commented Sep 19, 2017

I had a look at this today, the original value should probably be compared to make sure its the value it should be before we start patching incorrect bytes. This way we can identify if an offset changed easier besides a random crash.

@Drifter321
Copy link
Member

@Drifter321 Drifter321 commented Oct 28, 2017

Not tested but implemented the change. Compiles locally but fails with ambuild atm needs to be looked at. Regarding my previous crash i totally forgot the signature contained the actual patched bytes so we should be fine without checking. The gamedata also still seems to be good.

}
}

"Offsets"

This comment has been minimized.

@peace-maker

peace-maker Oct 28, 2017
Member

We could use the new "offset" key in the "Addresses" section here now!

Drifter321 added 2 commits Dec 4, 2017
Copy link
Member

@peace-maker peace-maker left a comment

Besides not aging well, this is still a very desired patch to do in SourceMod, not only to reenable plugin stats for CSGO servers, but allow custom tools to access the convars with the NOTIFY flag again as well.

if sdk_name == 'csgo':
project.sources += ['rulesfix.cpp']

binary = SM.HL2Config(project, 'game.cstrike.ext.' + sdk.ext, sdk)

This comment has been minimized.

@peace-maker

peace-maker Jul 9, 2020
Member

This change needs to be rebased against the arch changes in the build scripts.

@KyleSanderson
Copy link
Member

@KyleSanderson KyleSanderson commented Aug 17, 2020

@psychonic @Drifter321 what's the skinny on this one?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants
You can’t perform that action at this time.