Comments (2)
It seems like most of that page is talking about what we'd already planned, creating a new interface when we're adding new functions and giving plugins a way to use the latest interface version with a typedef (seeing as plugin devs shouldn't really have to worry about interface versions and should just be able to use the latest), I added in the typedef (+ a define that refers to the latest version) in 57bb54b
Although they seem to take a step further by also creating new versions of the class as well as the interface, I'm not really sure if we'd need to do that unless there were some drastic changes seeing as the new functions in the class should get mapped to the vftable of the new interface, and the vftables of each interface would be put one after another in the classes actual vftable (ie latest version would be at the end, at least it has from what I've seen), letting us just cast the class between each interface version.
Maybe we'll have to do some further testing to make sure these interface vftables are being placed properly though.
Also while the way we do this is weird, I mostly copied this style of interfaces and the CreateInterface function from Valve, eg. see https://developer.valvesoftware.com/wiki/IGameConsole
The Steamworks SDK also uses the same interfaces system, and I haven't really seen many problems coming from it.
from dewrecode.
Yeah, typedefs alone help greatly with readability. As long as we're waterfalling changes to separate versioned interfaces we should be able to somewhat depend on vftable ordering (CTRL+F to "figure 3" in the article), although it appears to be borderline undefined behavior and subject to change. I obviously trust Valve's choices over my limited knowledge on the subject however :)
from dewrecode.
Related Issues (20)
- Switching Network Type HOT 4
- Porting over custom packet code from ED HOT 13
- New people cloning repo can't build by default. HOT 4
- Debug Log Buffer Issues HOT 2
- MainMenu Checks / Host Checks HOT 3
- Login-based vs key-based authentication HOT 4
- Module system needs to be refactored HOT 7
- HOUI prefixes some strings with "@_" HOT 1
- Fixed Media\Settings menu crashes on most options HOT 1
- When holding more than one type of grenade while dual wielding, the sound of switching grenades is spammed repetedly
- Radar visibility being applied to wrong team? HOT 1
- Investigate equipment crashes HOT 3
- No assassination command/toggle HOT 2
- Dedicated server mode still requires DX9 HOT 5
- typo in stable/manifest.json
- In -dedicated mode everyone gets put on a single team HOT 1
- Improve ChatCommands plugin
- No respawn counter. HOT 3
- Fix the halo 3 scoreboard? (More of a problem if Multi-Team is fixed.) HOT 2
- Equipment and Weapon hud strings. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dewrecode.