Adamcake / Bolt

An alternative launcher for your favourite MMO
GNU Affero General Public License v3.0
122 stars 18 forks source link

How is var "s" injected into launcher.js #22

Closed thepure12 closed 4 months ago

thepure12 commented 4 months ago

I was looking at launcher.js to try to understand how it works, but I am not seeing where the variable/function "s" comes from.

Adamcake commented 4 months ago

It's defined in CEF's handlers. This deliberately obtuse, just to slightly improve my chances in case some first-party lawyers turn up.

The function is defined here: https://github.com/Adamcake/Bolt/blob/master/src/browser/app.cxx#L42 And the handler is here: https://github.com/Adamcake/Bolt/blob/master/src/browser/app.cxx#L109-L128 The launcher's onload event is to call start(s()), where the parameter is the variable called s in the rest of the code.

Don't spend too much time in app.cxx. CEF's render process implementation doesn't make any sense.

thepure12 commented 4 months ago

Awesome thanks.