Kindly help me - Cleo

Status
Not open for further replies.

Child_

Well-Known Member
Joined
May 9, 2015
Messages
115
Likes
0
Points
16
10
#1
So, I was going through the forums when I saw this script

Code:
{$CLEO .cs}

0000: NOP

:PEPE_22
wait 0
if and
0AD2: [email protected] = player $PLAYER_CHAR targeted_actor //IF and SET
0AB0: 49 // KEY 1
jf @PEPE_23
0B2B: samp [email protected] = get_player_id_by_actor_handle [email protected]
0AF9: "/arrest %d" [email protected]

:PEPE_23
wait 0
if and
0AD2: [email protected] = player $PLAYER_CHAR targeted_actor //IF and SET
0AB0: 50 // KEY 2
jf @PEPE_24
0B2B: samp [email protected] = get_player_id_by_actor_handle [email protected]
0AF9: "/e %d" [email protected]

:PEPE_24
jump @PEPE_22
It was for some CnR's where when you aim at a person and press 1, a command is given to arrest, and when you press 2 a command is giving '/e'

What I need is that if someone could replace '/arrest' with '/cuff' and replace '/e' with '/arrest'.

It'll be very helpful for me, thanks!
 
OP
OP
C

Child_

Well-Known Member
Joined
May 9, 2015
Messages
115
Likes
0
Points
16
10
#3
I actually tried this and it gave me some 'Unkown opcode 0B2B' error and when I try to run my game while installing this script, I crash at the startup, and I couldn't even decompile that script once its compiled.

So, Please kindly upload a .cs file.
 
OP
OP
C

Child_

Well-Known Member
Joined
May 9, 2015
Messages
115
Likes
0
Points
16
10
#6
Thanks mate, I'll try it out ASAP

edit; Dude, its exactly what I wanted, +r3p given <3
 
OP
OP
C

Child_

Well-Known Member
Joined
May 9, 2015
Messages
115
Likes
0
Points
16
10
#7
Nah, not working, I get exceptions and then I crash, it happens when I aim at someone and then press 1 or 2.
 

KillerZ

Well-Known Member
Joined
Apr 6, 2014
Messages
74
Likes
0
Points
6
5
#8
Do you have Sampfuncs 5.2.2?

Note: I even tried it in a CnR server and worked perfectly.
 

Attachments

OP
OP
C

Child_

Well-Known Member
Joined
May 9, 2015
Messages
115
Likes
0
Points
16
10
#9
lel, Didn't tried it with sampfuncs...

I'll try it now and give the response asap.
 

KillerZ

Well-Known Member
Joined
Apr 6, 2014
Messages
74
Likes
0
Points
6
5
#10
I tested it a bit more, and for me it only typed /cuff d, and server detects as 0 (basically only allows you to arrest id 0). Same with you?
 
OP
OP
C

Child_

Well-Known Member
Joined
May 9, 2015
Messages
115
Likes
0
Points
16
10
#11
Yup, It asks me to enter his ID, where as I'm aiming at that person.
 
OP
OP
C

Child_

Well-Known Member
Joined
May 9, 2015
Messages
115
Likes
0
Points
16
10
#14
Here

https://ugbase.eu/request-archive/a-keybinder-for-cops-and-robbers/
 
Joined
Jan 1, 2016
Messages
8
Likes
0
Points
1
1
#15
Very nice idea, but would it be possible to get the full name of the player instead of his id?
 
OP
OP
C

Child_

Well-Known Member
Joined
May 9, 2015
Messages
115
Likes
0
Points
16
10
#16
Well, Yeah.

If someone with a good knowledge about CLEO view's this topic.
 

springfield

Well-Known Member
Staff member
Joined
Feb 18, 2005
Messages
2,941
Likes
39
Points
98
Website
www.ugbase.eu
10
#17
Code:
{$CLEO .cs}
0000: NOP

REPEAT
    WAIT 100
UNTIL 0AFA:

WHILE TRUE
    WAIT 0
    IF 0AD2: [email protected] = $PLAYER_CHAR
    THEN
        0B2B: [email protected] = playerId [email protected] //get target samp id
        0B36: [email protected] = nickname [email protected] //get player name
        IF 0AB0: 49
        THEN 0AF9: "/arrest %s" [email protected]
        ELSE IF 0AB0: 50
            THEN 0AF9: "/e %s" [email protected]
            END
        END         
    END
END
 
Joined
Jan 3, 2016
Messages
10
Likes
0
Points
1
1
#18
The gay Gamer link said:
Well, Yeah.

If someone with a good knowledge about CLEO view's this topic.
So by that sarcastic comment you intentionally mean that springfield has "no knowledge about CLEO scripiting"?  :motherofgod_
 

HarrisonFord

Well-Known Member
Joined
Nov 25, 2013
Messages
115
Likes
0
Points
66
#19
This was funny.

First:
The gay Gamer link said:
Thanks mate, I'll try it out ASAP

edit; Dude, its exactly what I wanted, +r3p given <3
Then:
The gay Gamer link said:
Nah, not working, I get exceptions and then I crash, it happens when I aim at someone and then press 1 or 2.
Made my day xD
Reaction ->  :face_palm:
 
OP
OP
C

Child_

Well-Known Member
Joined
May 9, 2015
Messages
115
Likes
0
Points
16
10
#20
You got it wrong, I said it worked when it didn't gave out any exceptions, but when I really tried to use it, It didn't work, But I didn't made any new comment cause I didn't wanted Killer to rage, I just didn't wanted to be a asshole.
 
Status
Not open for further replies.
Top