Hello people, what I am trying to do is get a literal copy of a line in the chat and it's not working. What I mean by "it's not working" is that it doesn't get all the colour. Let's say you have multiple colours from the server in one chat line, the line will not get copied accordingly. An...
Hello dear scripters, I was researching on a function in LUA that can help me detect the click of a player. What I want my mod to do is be able to enable / disable the crosshair through right click and using the click of a player, it would do [/id <id of the player>]. I couldn't find a function...
Hello! I am trying to make a mod in LUA where if you press left arrow, the lights (both front and rear) on the left side of the car turn on. Similarily, if you press right arrow, the lights (both front and rear) on the right side of the car turn on. I've tried the only 2 commands that I found on...
Hello! I am making a mod, and part of it includes the player's name. Players on this server have clans, thus have clan tags. Typing [/id <id>] you get this (click). How can I get just the name of the player from this string? I think I could get the name and clan tag altogether from that string...
Hello dear scripters,
I am new to lua and I am trying to remove the last string from the chat. I don't really know how to do this and looking at lua docs, I can't find a way to do so.
Would anyone be able to help me? Thank you in advance
Hello dear scripters,
I want to make a script, where if you type command (/block <id>), it will get that user's name by ID and then make disappear any line that contains that player name. My problem is that I am not sure how to do this for multiple players. What I was thinking is to have an...
I tried making a code in-game so I don't have to keep quiting the game and re-enter and so on so my question is, why doesn't this work?
{$CLEO}
{$INCLUDE SF}
0000:
thread "TestsCMD"
repeat
wait 0
until SAMP.Available()
0B34: "restart" @restart
WHILE TRUE
WAIT 0
END
:restart...
Hey guys. I have thought of the idea of making a feature to a dialog that samp doesn't have it. So this is what I thought:
If you are on the first item of a dialog, and you press up arrow, it would automatically go to the last item and vice versa. So basically you wouldn't have to press down...
Hello! I want to make this as a call function but i am not sure how to use those and how to put them so they actually work. So here is what you have to do.
1. you will have command /teamag <id> <id> <id> <id>
2. for each of those id's you will type /number <id>
3. you will take the phone number...
Hei! So i see in a few cleo's things like this '0AA5: call 0x8220AD num_params 3 pop 3 5@ "%*[^,], %[^,]" 28@'. Now, this is just an example but i am confused about "%*[^,], %[^,]". How do you know which characters you need for what?
So i tried to make a confirmation system but it doesn't work...
So this is how it works. Once you type either /quitgroup or /quitclan, you will be displayed a dialog to ensure you want to quit the clan / group. After that, it will ask again in chat for key confirmation, so you have to press...
So on the server i play, you get notified when a friend joins the server. ( ). I have tried to get the name from the string, and edit the string but keeping the same name.. if that makes sense. Also, you can edit your desired sentence from game. So if you're in-game you can type /loginname Hi...
So the process of this job is the followng:
- get into bus, your checkpoint will appear
- drive to checkpoint
- when you arrive to checkpoint it says 'Please stop in the checkpoint.'
- After 2-3 sec the current checkpoint will disappear and another one will appear.
This process is repeated again...
If i have an active checkpoint from the server, how would i get the coords of this checkpoint? I need it for a job which keep gives you checkpoints, so i guess it's a race checkpoint. Also, i need something to check if race checkpoint is active, i could only find the ones used for normal...
So i tried to make a code which allows u to disable the checkpoint by pressing the key K.
When you press K it sees if there is an active checkpoint, then types /killcp, however, it crashes.
WHILE TRUE
WAIT 0
IF AND
NOT SAMP.ChatInputOpened()
key_down 75
THEN
IF 0AB1...
Hei. I'm not used to the idea of not using sampfuncs and recently i tried to help as many people as possible w their scripts and noticed a high percentage of these people dont use sampfuncs. Do you have any tips and tricks or anything i should know about working w no sampfuncs? (e.g how to start...
Hi! So i thought of this idea to see how many players driver car Y used for job X. Forget the job name, i just need to find out how many players driver a tractor for example, and make a variable to which you can add and substract 1 depending on how many people driver this vehicle. Can anyone help?
Okay, i might be a little stupid by making a billion posts on the same topic. I want to make a dialog which will show how many people are in certain job vehicles. If someone leaves / enters one of those vehicles, obviously the numbers will change. I am having trouble of figuring out how to...
On RP servers there are certain jobs. I want to know how many people are in the jobs' vehicles. I have done this so far however it isn't working properly, i get crash as i enter the game. I am not very experienced with this type of dialog.. Anyone help?
{$CLEO}
{$INCLUDE SF}
0000:
thread...
So on the server that i play there is this mission called Wang Cars Dealership. On the wall there are the names of 6 cars (like so ). I have tried both of these ( http://ugbase.eu/index.php?threads/textdraw-or-3dtextlabel-finder.17396/ ) (...
I want to make an input dialog (style 1) in which a command will be typed. How much memory do i need to allocate in order to store that command in a .ini file?
Hey, I've been thinking of a cleo however im not sure how to get the key that has been pressed. So if i press 'F' the key will appear in chat. I don't want to write 'if key_down {key}' for every existing key. Is there any way to make it quicker and cleaner?
HI! So I have been testing a few opcodes to see if i could automatically turn on the lights however, i have noticed that they are only turned on for me, not for the server i play on. The point is to set the car lights on while im in the car. The lights shouldnt be turned off at any time unless...
So I need a command that can take multiple parameters. I'm not 100% sure how to make this but im certain that what i've tried isn't working. Imagine you have a command [/test <string> <integer>]. String beind either 'info' showing a dialog or 'start' which then requiers you to also enter an...
Hi! I've made this car warning kind of thing for taxi drivers. Once it is lower than 500, it will put a warning in chat (chatmsg "warning" -1) however when i get in the car, i get lots of errors in chat then crash. May someone help?
// repair warning
IF AND
25@ == 1
0602: actor...
Hi. How can I check for active checkpoint? I have only found a few opcodes that only create and other few things but not what i need. Can someone help me please?
So my aim is to select the 1st/2nd/3rd/4rd item of the dialog '/clan' which is a server dialog. The problem is that none of the commands dont work... which im not sure why.. Can anyone help please?
{$CLEO}
{$INCLUDE SF}
0000:
thread "ClanCMD"
repeat
wait 0
until SAMP.Available()
chatmsg...
So I have a script with multiple ideas but to be neater, i wish to make 2 .cs files that could link to a common dialog. For example in 1.cs i have /servercmd (example) and if it will choose the 2nd item it will activate 2.cs continuing with the script from the 2nd .cs file. Is that possible?
So I've thought of this idea of writing a specific message from the game. What i need exactly is the dialog box with the list of strings added throughout the game. The proccess is:
> Type command [/list] (example)
> Show the empty dialog with 2 buttons ADD and CLOSE
> When press CLOSE, close...
Hello again. I've tried to make this fancy way of writing a string into a .ini file instead of just making a boring command however it doesnt work very well.
0B34: "acommand" @acommand
WHILE TRUE
WAIT 0
IF SAMP.DialogRespond(1000, 2@, 0, 3@)
THEN
IF 2@ == 0
THEN...
So I've tried to make this cool autoclicker however it doesn't respond when i type the text in the chat... anyone knows why? Also, how would i test for the colour of the text too?
{$CLEO}
{$INCLUDE SF}
0000:
thread "AutoClicker"
repeat
wait 0
until SAMP.Available()
0B34: "autoclicker"...
So I've tried to make a textbox once the whole script has been running but when i test it in game, nothing happens.
alloc 2@ 260
0B75: samp get_chat_string 99 text_to 2@ prefix_to 3@ color_to 4@ prefix_color_to 5@
if or
4@ == 0xffffd700
4@ == 0xff4dad2b
then...
Hi! So I know there are more types of "Titles" for example chatmsg, printstring, etc.
Does anyone know how many there are and how they look like? Or if there is a link to such a thing? Thanks a lot!
So I've done this code, with the help of one of the members of this community, BUT it doesn't work rlly well and it crashes. I'm not sure if i need to allocate any memory or anything. Can someone help?
--> Here's some videos to show the problem
- /balance (it writes the right value in .ini file...
So what I've tried to do is to get the value from the chat and write it in .ini file.
This is the string : Your account balance is now $25.255.525. It doesn't work. It just gives a lot of errors then crashes.
alloc 2@ 260
0B75: samp get_chat_string 99 text_to 2@ prefix_to 3@ color_to 4@...
So I've been trying to get the car's speed in order to make a limiter, if that makes sense, although it doesn't work and i dont really find the mistake.. Can someone help please?
0AF0: 5@ = get_int_from_ini_file "cleo\ServerCMD.ini" section "AntiTicket" key "states"
0AF0: 7@ =...
So in .ini file I put the value $2.500.512 and i made a dialog in which it would show the value. Here's the code
if and
20@ == 1
21@ == 2
then
0AC8: 29@ = allocate_memory_size 75
0AF4: 29@ = read_string_from_ini_file "cleo\ServerCMD.ini" section...
So I've tried to make a code in order to see player's color, for example, if a player is in a faction and has a different name color, i could see what that color is.
Here's the code:
{$CLEO .cs}
thread "PlayerColor"
0000:
repeat
wait 0
until SAMP.Available()
0B34: "playercolor"...
So I tried to make a script in which when the following is been said, it would say the next things in "" but it doesn't work... Can anyone help me please?
{$CLEO .cs}
thread "Auto-Clicker"
0000:
repeat
wait 0
until SAMP.Available()
while true
wait 0
SAMP.GetChatString(1@...
Hi! So I've been questioning this to myself for a long time and looked at some examples of codes which used TXD ID. I can't figure it out how to get the TXD ID from the screen... if you know what i mean.. The server I currently play on has a HUD when you enter the car, which tell you the speed...
So I tried to make a script in which when the following is been said, it would say the next things in "" but it doesn't work... Can anyone help me please?
{$CLEO .cs}
thread "Auto-Clicker"
0000:
repeat
wait 0
until SAMP.Available()
while true
wait 0
SAMP.GetChatString(1@...
So... I've tried this piece of code out and see if it works... It certainly doesn't work as I would expect it to..
Code:
if SAMP.DialogRespond(830, 20@, 0, 25@)
then
if 20@ == 1
then
0C1A: 26@ = atoi 25@
if SAMP.IsPlayerConnected(26@)
then...
Hey. So ive tried to make a new script or something that i'd be able to use in a project i'm working on even though i'm not sure how to solve this.
So here's the script:
if SAMP.DialogRespond(830, 20@, 0, 25@)
then
if 20@ == 1
then
0C1A: 26@ = atoi 25@...
Hi! So I've tried to make this automatic ish thing that would eventually set a frequency you've input by using /freqno or if you type /freq off it'd turn it off but when i type /freq on or /freq off it crashes. Can this be solved??
Hi! I've tried to make a script in which when I enter a vehicle of type "Bike" it types /puthelmet automatic BUT if I go from a NRG-500 to a normal Bike, it says an error, as i'd be in a car. Anyone knows how to improve this script? Thanks
0AF0: 2@ = get_int_from_ini_file "cleo\ServerCMD.ini"...
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...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.