Jump to content

[Help] Difference between Server side and Client side


GamingTim

Recommended Posts

https://wiki.multitheftauto.com/wiki/Scr ... troduction

"You may have already noticed these or similiar terms (Server/Client) somewhere on this wiki, mostly in conjunction with functions. MTA not only supports scripts that run on the server and provide commands (like the one we wrote above) or other features, but also scripts that run on the MTA client the players use to connect to the server. The reason for this is, that some features MTA provides have to be clientside (like a GUI - Graphical User Interface), others should be because they work better and still others are better off to be serverside or just don't work clientside."

If you still don't understand, feel free to leave another message.

Link to comment
So basically Client side is for player commands in game while server side is for like Gui? and how do i know if i were to make a gamemode, how do i know if its server side or client side or both?

Complete opposite, serverside is for commands and such but GUIS are clientside. If you go on the wiki you can find functions and events. Most of them are categorized as clientside or serverside, you cannot use a clientside event/function serverside etc. You might want to put most of your code serverside as clientside scripts get downloaded and become accesible, they're still compiled hopefuly. Sooo : Put everything important serverside. When you're using MYSQL, you'll see that you cannot use mysql functions clientside just because putting things client side isn't considered safer than serverside.

Link to comment

It's pure English.

CLIENT-side

SERVER-side

Stuff that are ran on the client's (aka player) computer go CLIENT-side.

Stuff that are ran on the server go SERVER-side.

Servers are unable to render graphics because they're not meant to do that, that is why GUIs and DX-functions are CLIENT-side.

If you want to make all your commands CLIENT-side, go ahead, but they won't be synchronized with the SERVER-side, and SERVER-side synchronizes ALL clients. This means if you create a vehicle CLIENT-side, it will be only shown to the CLIENT that was meant to see it.

It's quite logical after all.

  • Like 1
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...