Alittle help scripting something quite advanced... PLEASE! -
soryy708 - 10.05.2009
Hey guys!
Im scripting something unique so i wont get in big details
Basicly, I dont know how to script something so please help me
What I want it to do:
When a player logs-in, there is a variable defined to his slot. By default, it's value is 0. If he types "/blogin [blogin password]", it will set the variable to 1.
Please, help me!
Re: Alittle help scripting something quite advanced... PLEASE! -
Weirdosport - 10.05.2009
Search the forums for a user/admin system, and just add the variable setting thing to the login command...
It'd probably help if you knew how to script, but in essence here is what you need:
Globally:
pawn Код:
new VariableName[MAX_PLAYERS];
In Login Command:
pawn Код:
VariableName[playerid] = 1;
Re: Alittle help scripting something quite advanced... PLEASE! -
soryy708 - 10.05.2009
Waiting for a helping reply
Dude I dont know how to use variables in PAWN... Thats the whole problem!
Re: Alittle help scripting something quite advanced... PLEASE! -
Backwardsman97 - 10.05.2009
He just told you. You pretty much explained how when you were asking. If you can't understand from that, look at the wiki, examples included in the server package, and the pawn language pdf.
Re: Alittle help scripting something quite advanced... PLEASE! -
Weirdosport - 10.05.2009
Quote:
Alittle help scripting something quite advanced
|
Frankly, this is piss easy stuff, it's only a step up from the bog standard stuff I'd teach total beginners.. As Previous Poster says, you should look on the wiki, or at some tutorials or something..
And if you don't know how to use variables in pawn, it doesn't leave much..
Re: Alittle help scripting something quite advanced... PLEASE! -
soryy708 - 10.05.2009
Hmmm... I guess I wont need scripting a whole register / login system! :P
Tyvm guys I will test those 2 now.
Re: Alittle help scripting something quite advanced... PLEASE! -
soryy708 - 10.05.2009
Thanks guys, i am scripting it right now.
But by the way, I thought and I'd need some help... How can I make Pawno create an .ini and store the variable ammount in it?
( Btw i called this advanced because some medium-leveled scripter that i asked couldnt do it. )
Re: Alittle help scripting something quite advanced... PLEASE! -
DMSOrg - 10.05.2009
Must not be very medium level.
There's a native called fWrite, look at that and figure it out from there
Re: Alittle help scripting something quite advanced... PLEASE! -
Weirdosport - 10.05.2009
If you're a beginner you'd be best off using Dini as opposed to fwrite. (Dini does the more complicated fwrite bits for you).
If you just search for Dini I can guarantee it will be there, by "Draco Blue"