Official Soldat Forums
Server Talk => Scripting Discussions and Help => Topic started by: trickster on September 22, 2008, 09:31:59 pm
-
hey guys again me and my questions ...
my first question...
how do i create classes like berserker class and anything can someone give me an example script please i really want to learn gow to...
my second question...
how do i create my skills but only a certain class can use some and the other class diferent skills??
i know how to create the bullets and anything i just want an example of how a class can have some unique skills and another class can use his unique skill
if someone can answer or give me a script example please tell me right away
-
I'm assuming that you are pretty experienced because that is a fairly complex thing to do.
To create a class I would suggest making a struct/type thing that stores the basic things. Avarax uses this in MMod:
tClass = record
name,description: string;
skill: array[1..4] of string;
weap: array[0..14] of boolean;
Human: boolean;
input,output,inmod,outmod,PickX,PickY: integer;
BCount,ICount: byte;
end;
Then you just need to initialize all of them and check for their spells when they do stuff.
For #2, just save what class each person is in, and when they do a command associate that with their class...
Script example: http://nopaste.com/p/a0soFkyNM
-
avarax mod script example looks a bit complicated, is there another way?? because im not the one to spend soo much time understanding and making a big script
-
all u do is set a varrible berseker := ID on player command, and like if you want t have skills only for this class u can do onplayercommand if berseker = id bla bla