The International Simutrans Forum

Development => Scripting Scenarios and AI => Topic started by: Yona-TYT on August 25, 2017, 02:53:26 AM

Title: [Online] Authorize script call
Post by: Yona-TYT on August 25, 2017, 02:53:26 AM

Hi, how are you.

I am thinking of using the script  links "http://forum.simutrans.com/index.php?topic=17135.msg163121#msg163121 (http://forum.simutrans.com/index.php?topic=17135.msg163121#msg163121)" to improve the project of maps divided into regions.

The problem is that it can not be used in multiplayer mode, since there is no security measure that prevents an unauthorized player from using it.

Script -> regions-lite.zip (http://files.simutrans.com/index.php/s/QvrfXWHA0AkXFvV)


I hope that in the future it can culminate with this project, GREETINGS !!.  ;)

(http://files.simutrans.com/index.php/apps/files_sharing/ajax/publicpreview.php?x=1440&y=372&a=true&file=shared_region.png&t=zTsSp4mv0RL4uJV&scalingup=0)
Title: Re: [Online] Authorize script call
Post by: DrSuperGood on August 26, 2017, 12:02:57 AM
I do not know much about the internal working of the scripting engine. However from previous times it was requested the conclusion was that it would require non-trivial changes to the client/server system used so that players can be aware of other players and their authentication status with companies.
Title: Re: [Online] Authorize script call
Post by: Dwachs on September 01, 2017, 04:58:53 PM
Player authentication can be done.

However, somebody has to check whether script calls send by clients are allowed to be executed. Otherwise, a maliciously modified client can send invalid scenario calls, and thus ruining the game.
Title: Re: [Online] Authorize script call
Post by: Yona-TYT on September 01, 2017, 10:44:56 PM
@Dwachs

I can think of the following:  ;D

Use the toll signal window to authorize or not a player.

(http://files.simutrans.com/index.php/apps/files_sharing/ajax/publicpreview.php?x=1440&y=372&a=true&file=signial_regions.png&t=zE1veHjbOVaHwlP&scalingup=0)

is it possible to know if the player is authorized to use the toll ?.