Creating a server var?
#1

Hey, i've seen it been done before.. Whats the function to do it?
Reply
#2

new servervar;
Reply
#3

pawn Код:
new Example;
and you would use this as.

(say you were using it to track somthing)

pawn Код:
if(Example == 1)
---------------------------------
For a global variable.
-
pawn Код:
new Example[MAX_PLAYERS];
and you would use that as. Example[playerid];
Reply
#4

Quote:
Originally Posted by -Rebel Son-
Посмотреть сообщение
pawn Код:
new Example;
and you would use this as.

(say you were using it to track somthing)

pawn Код:
if(Example == 1)
---------------------------------
For a global variable.
-
pawn Код:
new Example[MAX_PLAYERS];
and you would use that as. Example[playerid];
They are both global variables, providing you don't limit the scope by placing the variables/arrays within a function.... The second example is an array with the dimensions of MAX_PLAYERS (500) so 500 cells are created as integers.
Reply
#5

Not SCRIPT Var's.. Server vars. Custom ones.
For Example
Код:
weburl www.******.ca
Show's up in the SAMP client to the right, I've seen custom ones done, and am wondering how to do that.
Reply
#6

you change the weburl in the server.cfg, other things such as gravity, world time and weather can be done in the script using functions such as SetGravity, SetWorldTime or SetWeather
Reply
#7

You people should spend a while reading.
connor, if you mean something like

It can be done by using YSF Plugin
I literally ******d a bit, and found this https://sampforum.blast.hk/showthread.php?tid=136102
This is where i got the information from, although i can't offer you any help with YSF as I've never used it.

Good luck!
Reply
#8

I believe https://sampforum.blast.hk/showthread.php?tid=113485 is it
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)