Cleo Sripting ( Sanny Builder )

Status
Not open for further replies.

KamikazeSripterul

Well-Known Member
Joined
Jun 30, 2019
Messages
61
Likes
1
Points
8
#1
I tried to make a long dialog in which you can have several choices but certain this script is right because as I try to join the game, it shows a lot of errors in chat and then it crashes. What's wrong with the script?

{$CLEO .cs}
thread "CivilCMD"
0000:

repeat
wait 0
until SAMP.Available()
// Commands
0B34: "civilcmd" @CivilCMD
0B34: "maincmd" @MainCMD
// When game starts shows:
chatmsg "{ff0000}CivilCMD for bugged.ro." -1
chatmsg "{ff0000}Use {ffff00}/civilcmd {ff0000}for more detail" -1
while true
wait 0
if SAMP.DialogRespond(266, [email protected], [email protected], 0)
then

if [email protected] == 1
then

if [email protected] == 0
then
0AC6: [email protected] = label @Jobs
SAMP.ShowDialog(255, "{fff252}» {57377c}Jobs", [email protected], "Select", "Back", 2)
else
if [email protected] == 1
then
0AC6: [email protected] = label @Shortcuts
SAMP.ShowDialog(277, "{fff252}» {57377c}Shortcuts", [email protected], "Select", "Back", 2)
else
if [email protected] == 0
then
0AC6: [email protected] = label @MainCMD offset
SAMP.ShowDialog(266, "{c8a5e7}» CivilCMD {ff0000}Jobs {00ff00}Prescurtari" , [email protected], "Select" , "Exit", 2)
0B49: samp set_current_dialog_list_item -1
end
end
end
end
end
if 0B3C: samp is_dialog_responded id 255 button [email protected] list_item [email protected] input_text 0
then

if [email protected] == 1
then
if [email protected] == 0
then
0AC6: [email protected] = label @JobList
SAMP.ShowDialog(256, "{ff0000}» {57377c}Jobs", [email protected], "Menu", "Back", 2)
else
if [email protected] == 1
then
0AC6: [email protected] label @JobHelp
SAMP.ShowDialog(257, "{00ffff}» {57377c}Job Help", [email protected], "Exit", "", 2)
else
if [email protected] == 0
then
0AC6: [email protected] = label @Jobs
SAMP.ShowDialog(255, "{fff252}» {57377c}Jobs", [email protected], "Select", "Back", 2)
end
end
end
end


END

// Introduction
:CivilCMD
if SAMP.IsCommandTyped([email protected])
0AC6: [email protected] = label @CivilCMDText offset
SAMP.ShowDialog(7777, "» CivilCMD", [email protected], "Close", "", 0)
SAMP.CmdRet
:CivilCMDText
HEX
43 69 76 69 6C 43 4D 44 20 74 65 20 61 6A 75 74 61 20 63 75 20
6F 72 69 63 65 20 70 65 20 62 75 67 67 65 64 2E 72 6F 21 20
54 6F 74 20 63 65 20 74 72 65 62 75 69 65 20 73 61 20 73 74
69 69 20 64 65 73 70 72 65 20 73 65 72 76 65 72 2E 20 4A 6F
62 73 20 26 20 73 68 6F 72 74 63 75 74 73 2E 0A 54 61 73 74
65 61 7A 61 20 2F 6D 61 69 6E 63 6D 64 20 70 65 6E 74 72 75
20 61 20 61 63 63 65 73 61 20 6D 61 69 20 6D 75 6C 74 65 20
64 65 74 61 6C 69 69 2E 00
END
// Main / Extract
:MainCMD
if SAMP.IsCommandTyped([email protected])
0AC6: [email protected] = label @ChoiceJS offset
SAMP.ShowDialog(266, "{c8a5e7}» CivilCMD {ff0000}Jobs {00ff00}Prescurtari" , [email protected], "Select" , "Exit", 2)
SAMP.CmdRet()
:ChoiceJS
HEX
">> Jobs <<" A
">> Prescurtari <<" 0
END
:Jobs
HEX
">> Jobs <<" A // :JobList
">> (!) Ajutor (!) <<" 0 // :JobHelp
END
:JobList
HEX
"{ff0000}>> Citeste-ma! <<" A
">> Fisher" A
">> Arms Dealer" A
">> Detective" A
">> Mechanic" A
">> Car Jacker" A
">> Pizza Boy" A
">> Trucker" A
">> Bus Driver" A
">> Drug Dealer" A
">> Garbage Man" A
">> Farmer" A
">> Boat Transporter" 0
END
:JobHelp
HEX
"Cu ce ma ajuta selectarea unui job din lista anterioara?" A
"Ce se intampla daca selectez un job?" 0
END
:Shortcuts
HEX
">> Prescurtari <<" A // :ShortcutsList
">> (!) Ajutor (!) <<" 0 // :ShortcutsHelp
END
 

SebiTalent04

Well-Known Member
Joined
Aug 16, 2017
Messages
64
Likes
2
Points
23
Location
Romania
Website
beeg.com
#2
convertește stringurile în hex și o sa mearga
HEX
">> Jobs <<" A
">> Prescurtari <<" 0
END
:Jobs
HEX
">> Jobs <<" A // :JobList
">> (!) Ajutor (!) <<" 0 // :JobHelp
END
:JobList
HEX
"{ff0000}>> Citeste-ma! <<" A
">> Fisher" A
">> Arms Dealer" A
">> Detective" A
">> Mechanic" A
">> Car Jacker" A
">> Pizza Boy" A
">> Trucker" A
">> Bus Driver" A
">> Drug Dealer" A
">> Garbage Man" A
">> Farmer" A
">> Boat Transporter" 0
END
:JobHelp
HEX
"Cu ce ma ajuta selectarea unui job din lista anterioara?" A
"Ce se intampla daca selectez un job?" 0
END
:Shortcuts
HEX
">> Prescurtari <<" A // :ShortcutsList
">> (!) Ajutor (!) <<" 0 // :ShortcutsHelp
END
 
Status
Not open for further replies.
Top