How to make a basic clan system?
#1

I'm trying to make a clan system with the following commands:

1) /createclan [tag] [name]
2) /invite
3) /kick
4) /members

I want that when a player joins the clan, the tag of the clan which he joined is automatically input beside his name.

e.g. David joins the clan Crazy Killas [CK]

Now his name is [CK]David without him doing anything.
Reply
#2

You will need to use SQL database and store the clan ID in the player table. and make a separate table for clans. When player connect and has logged in, check if the player clan is valid or not, if it is not valid, make the clan id in his stats to 0/ invalid and if it is valid, give that player the clan tag fetched from the database or the script variables. this can also be done with other saving systems but it will be too slow.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)