class system help???
#1

I want create a Trucking/Missions server and i need help i dunno how to.



Can be 2 variants, better i will like variant 1



1.variant
When joins server Opens a dialog: (to select the job classe)

Trucker
Police
Pilot
Taxi driver
Mafia
Sailor
Pizza man
Bus driver
Firefighter
Mechanic
Farmer
Postman
Train driver

When selected job classe shows skins what to choose: (on selected job classe)

When selected the skin opens dialog where to spawn: (with selected skin in selected job classe)

And spawn the player in selected job classe with selected skin and with classe color:



2.variant
When joined server shows the skin and class name.

When selected the skin opens dialog where to spawn: (with selected skin in selected job classe)

And spawn the player in selected job classe with selected skin and with classe color:


JOB CLASSES = COLORS (colors can be different from exampe i will change them)
------------------------------
Trucker = yellow
Police = dark blue
Pilot = dark green
Taxi driver = green
Mafia = orange
Sailor = light blue
Pizza man = pink
Bus driver = purple
Firefighter = black
Mechanic = gray
Farmer = lime green
Postman = dark gray
Train driver = dark green

Police job score limit 300
Mafia job score limit 150
Pilot job score limit 100
Firefighter job score limit 60
Sailor job score limit 40
Reply
#2

It's great to hear what you want to be made.

edit, i won't be that harsh

Sadly we won't make anything you request here, as this is "Scripting help", not Scripting requests, so you can either go to this thread and search for a developer that's going to make it for you, you can post your code here that you have made, an attempt is more than enough but don't do like one single line and expect us to write the rest.

Here's a little begin for you.

pawn Код:
public OnPlayerConnect(playerid)
{
ShowPlayerDialog(playerid, 7376, DIALOG_STYLE_LIST, "Select Job", "Trucker\nPolice\nPilot\nTaxi driver\nMafia\nSailor\nPizza man\nBus driver\nFirefighter\nMechanic\nFarmer\nPostman\nTrain driver", "Select Job", "");
}
(although i think that's too long and you should use strcat for it)

And for it's responses you could use this.

Here's a little online pawn-ish kit which you can use. (I used that to make that pawn line above^^)

https://app.pawnokit.ru/en/tools/createdialog.html

Easy, but don;t expect us to write enormous amount of lines
Reply
#3

Start off by showing the dialog in OnPlayerConnect:
https://sampwiki.blast.hk/wiki/ShowPlayerDialog
It should be a DIALOG_STYLE_LIST ofc.
Then you can check what the player picks using listitem in OnDialogResponse:
https://sampwiki.blast.hk/wiki/OnDialogResponse

Read those 2 wiki articles, there's also examples.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)