August 02, 2021, 11:42:43 am

The Gang Garrison 2 Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

NOTICE: Due to a rise in bot activity, new posters need to be approved before posting.

Join the community Discord server!

Pages: 1 2 [3]

Author Topic: Server-sent plugins FAQ  (Read 30561 times)

ZaSpai

  • Ray Bann's Minion
  • *
  • Karma: 14
  • Offline Offline
  • Posts: 2239
  • "Eeh?! We're just allies!"
Re: Server-sent plugins FAQ
« Reply #30 on: February 26, 2014, 08:10:33 pm »

Question: if a server host uses an unapproved/unauthorized SSP run from ServerPluginsDebug, is a client (excluding a multiclient from the same machine) able to download that unauthorized SSP from the host, or will the attempt to join fail?
Logged
Right behind you when you most expect it | classicwell master race

notarctic

  • just arctic, what gives?
  • ******
  • Karma: 8
  • Offline Offline
  • Posts: 4904
  • 👎👀 bad aim ba̷̶ ԁ aIm 👎 thats❌ some bad 👎👎aim
    • arcticland
Re: Server-sent plugins FAQ
« Reply #31 on: February 26, 2014, 10:40:18 pm »

its simple, it wont work. iirc the message you get from loading from using debug describes everything. even if the client manages to join, depending on what you're doing, the client will receive unexpected data or desync or both
Logged
[1:37:51 PM] Derpduck: arctic u need to quote ppl that make shit posts in case they edit them
[4:20:15 PM] Rubeus Hashgrid: i cant discover anything fuck you imageshack

ZaSpai

  • Ray Bann's Minion
  • *
  • Karma: 14
  • Offline Offline
  • Posts: 2239
  • "Eeh?! We're just allies!"
Re: Server-sent plugins FAQ
« Reply #32 on: February 26, 2014, 10:43:33 pm »

its simple, it wont work. iirc the message you get from loading from using debug describes everything. even if the client manages to join, depending on what you're doing, the client will receive unexpected data or desync or both
So essentially the client will need to have the SSP in question in their ServerPluginsDebug as well I probably meant ServerPluginsCache or something nvm it was ServerPluginsDebug for anything to work

Coolies
« Last Edit: February 27, 2014, 02:59:14 am by ZaSpai »
Logged
Right behind you when you most expect it | classicwell master race

ajf

  • (Ex-?)Developer and forum/web admin
  • *****
  • Karma: 7
  • Offline Offline
  • Posts: 3492
  • she's never quite as dead as you think
Re: Server-sent plugins FAQ
« Reply #33 on: February 27, 2014, 07:15:46 am »

its simple, it wont work. iirc the message you get from loading from using debug describes everything. even if the client manages to join, depending on what you're doing, the client will receive unexpected data or desync or both
So essentially the client will need to have the SSP in question in their ServerPluginsDebug as well I probably meant ServerPluginsCache or something nvm it was ServerPluginsDebug for anything to work

Coolies
Right.

When the server starts, it finds the MD5 hash of each plugin and generates a new list containing that info, e.g. can_you_feel_the_sunshine@ca77b909b9fdf6655103dcdada4032b0,buffpyro@96fb7f3f779948f40935b89fc3b56399.

The client is sent that list when it connects. It'll then look in three sources, in order:

If your plugin in ServerPluginsDebug happened to have the same name as an actual plugin, and happened to have the same MD5 as an actual version if that plugin (which is unlikely unless it actually is that version of that plugin), then your client would be able to download it from the server fine. Most likely, however, that won't be the case, and it'll bring up an error saying it couldn't find the plugin on the server, unless you had it in ServerPluginsDebug or ServerPluginsCache.
« Last Edit: February 27, 2014, 07:17:18 am by ajf »
Logged
aka Andrea.

did you know that spinning stars work like this???

I've seen things you people wouldn't believe. execute_strings on fire off the shoulder of Overmars. I watched object-beams glitter in the dark near the room_goto_fix. All those moments will be lost in time, like tears...in...rain. Time to die.

ajf

  • (Ex-?)Developer and forum/web admin
  • *****
  • Karma: 7
  • Offline Offline
  • Posts: 3492
  • she's never quite as dead as you think
Re: Server-sent plugins FAQ
« Reply #34 on: July 13, 2014, 06:31:31 am »

Updated to note v2.7.3's PluginEnvironments.

A summary of the changes can be found here:

btw what changes with the 'plugins run in own environment'?
Ah, I should update the plugin FAQ about that. Basically, we spawn a new PluginEnvironment instance (it's a persistent, invisible object) and do with(env) { execute_file(...); } so any variables you forget to define will end up on that object instead of on GameServer, Client or the weird non-object game_init runs in.

It also means you can now just type 'packetID' and 'directory' to get the packet ID or directory, respectively, since we put those as variables on the object for you. There's also isLocalPlugin and isServerSentPlugin for checking what mode the plugin's running in.

This also gives you a nice place to stick your variables. For my latest plugin, I did this:

globalvar myplugin;
myplugin = id; // this PluginEnvironment object

blah = 3;
foobar = "stuff";

...

if (myplugin.blah) {
    ...
}

Logged
aka Andrea.

did you know that spinning stars work like this???

I've seen things you people wouldn't believe. execute_strings on fire off the shoulder of Overmars. I watched object-beams glitter in the dark near the room_goto_fix. All those moments will be lost in time, like tears...in...rain. Time to die.

ajf

  • (Ex-?)Developer and forum/web admin
  • *****
  • Karma: 7
  • Offline Offline
  • Posts: 3492
  • she's never quite as dead as you think
Re: Server-sent plugins FAQ
« Reply #35 on: July 29, 2014, 08:40:21 pm »

The OP now mentions where to find Faucet Networking documentation, by arctic's request. Which is a good idea, since it's not immediately obvious that the docs are in PDF form in the release ZIPs.
Logged
aka Andrea.

did you know that spinning stars work like this???

I've seen things you people wouldn't believe. execute_strings on fire off the shoulder of Overmars. I watched object-beams glitter in the dark near the room_goto_fix. All those moments will be lost in time, like tears...in...rain. Time to die.
Pages: 1 2 [3]
 

Page created in 0.039 seconds with 36 queries.