CLEO Help How to use Dialog Slider...

CLEO related
Status
Not open for further replies.

MalikeiraOPoder

Active member
Joined
Mar 16, 2019
Messages
100
Reaction score
2
Guess whos back again? xD


So.. i have a question, how can i use a slider to define a value ?

this is a example code

PHP:
{$CLEO .cs}

0000: NOP

REPEAT
   WAIT 0
UNTIL 0AFA:


Dialog.Create(5@, " ")
Dialog.SetRECT(5@, 479, 486, 257, 115)
Dialog.AddCheckBox(5@, 1, "Long Jump", 5, 25, 210, 25)
Dialog.AddButton(5@, 2, "Config", 165, 25, 85, 30)
Dialog.AddButton(5@, 300, "Close", 55, 60, 90, 25)
Dialog.SetVisible(5@,0)
Dialog.SetMinimized(5@, 0)


Dialog.Create(6@, "Settings")
Dialog.SetRECT(6@, 527, 652, 255, 141)
Dialog.SetVisible(6@,0)
Dialog.SetMinimized(6@, 0)

0B34: "dialog" @ShowDialog

while true
wait 0

        if Dialog.IsVisible(5@)
        then
            SAMP.ToggleCursor(1)
            if Dialog.PopEvent(5@, 2@, 3@)
            then         
                if and
                3@ == 300 // ID
                2@ == 257 // Button Pressed
                then
                    Dialog.SetVisible(5@,0)
                    SAMP.ToggleCursor(0)
                end
              
            end
        end
        
                        if 
                        Dialog.CheckBoxIsChecked(5@,1)
                        then
                        if and
                        00E1:   player 0 pressed_key 14 
                        00E1:   player 0 pressed_key 16 
                           not Actor.Animation($PLAYER_ACTOR) == "CLIMB_JUMP"
                           Actor.Animation($PLAYER_ACTOR) == "JUMP_GLIDE"
                        then
                        15@ = Actor.Angle($PLAYER_ACTOR)
                        12@ = 0.0 
                        wait 0 
                        Actor.SetImmunities($PLAYER_ACTOR, 0, 0, 0, 1, 0)
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        083D: get_actor $PLAYER_ACTOR velocity_in_direction_XYZ 1@ 2@ 3@ 
                        1@ *= 2.0     // ====================================== To change this value   id 1
                        2@ *= 2.0     // ====================================== To change this value    id 1
                        1@ *= 2.0     // ====================================== To change this value    id 1
                        2@ *= 2.0     // ====================================== To change this value    id 1
                        083C: set_actor $PLAYER_ACTOR velocity_in_direction_XYZ 1@ 2@ 8.0   // and this value "8.0"    id 2
                        0812: AS_actor $PLAYER_ACTOR perform_animation "FALL_FALL" IFP "PED" framedelta 3.0 loopA 0 lockX 0 lockY 0 lockF 0 time 440 // versionB 
                        wait 50 
                        12@ += -10.0 
                        wait 1 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 18 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -15.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -20.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -20.0 
                        wait 15 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -20.0 
                        wait 18 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 15 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -10.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -7.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -6.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -5.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -4.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -3.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -2.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        12@ += -1.0 
                        wait 5 
                        083E: set_actor $PLAYER_ACTOR rotation 12@ 0.0 15@ while_in_air 
                        083E: set_actor $PLAYER_ACTOR rotation 0.0 0.0 15@ while_in_air
                        wait 600 
                        END
                        end
        
        
        
end

:ShowDialog
Dialog.SetVisible(5@, 1)
SAMP.ToggleCursor(1)
0B43:

i did the dialog 6@ to do the Dialog Slider, but i failed :/

How can i do 2 Slider to dialog 6@ to change the value from Long Jump ?
 
Status
Not open for further replies.
Top