That still doesn't work. This is what I did:
local events = require("lib.samp.events")
function events.onServerMessage(color, text)
sampAddChatMessage(text, -1)
end
I even tried instead of -1 to put color but it shows pink
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...
The only issue with this is that i dont know what the clan tag is. I cant just write every single clan tag from the server and always update it when a clan is registered/deleted. The only possible way (as far as i thought), is to get the colour from the chat of the clan tag, and remove that from...
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
The idea of this mod is to hide messages from people that you want to block. You type /block 7, the person with the id 7 will no longer appear on your chat. If someone is annoying you or whatever.
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...
That is what I explained in the description of the post but I guess I just explained it badly because I already have @SpnKO 's suggestion. I am struggling on this idea of having a main code that restarts the written one but I don't understand why it doesn't work.
If you are testing something and don't want to keep quit the game and enter again for the cleo to update, I tried updating from in game however I wanted to make a command that has the parameter as the name of the file instead of putting this command in every cleo i will create at one point.
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...
From what I understood the server spawns the truck 50m away after you've completed a delivery. I guess it doesnt kick you out, it just deletes the truck. I'm not sure if you could.. idk respawn the truck? But maybe that will interfere IDs or idk. Actually, i think the ID doesnt change of the...
@ShalltearB Okay so you obviously have the snippet from Zin. You can show the coordinates using 'chatmsg "%f %f %f" 1@ 2@ 3@'. Just so you understand, %f represents float numbers (such as 2.1, 3.4 etc.), %d represents whole numbers (such as 1, 2 etc.) and theres many more. All coordinates in...
Yeah its possible. Start by checking for each textdar id 0 to 2304. Search in opcode 'scan_string' , 0c18 or 0c14 (whichever js suitable for u) and use the format you need to find that textdraw. Finally, take the text of tjat textdraw and create the textdraw.
La sfarsit de hex pui 00, aia segnificand ca termini hex-ul. Adica vei avea '7d 00'. Nu vad un motiv de ce nu ar merge codul lui cheetahftw1, probabil e din cauza versiunii sampfuncs sau cleo, poate chiar si samp. La ce ai nevoie de acest cmd? Pe ce server? Trimite pe prv.
Isnt that.. a bit useless? I mean.. you could make a bind on space.. if u press space it starts if u press space again it stops. Idk, its more.. easier to use i guess. I dont see a point in this though but alright.
Ok so i have made a code b4 getting the closest players name/id. Ill send you both and you can decide which one you want and how you gonna use it. You can think of it as a snippet and use it in the way you want. You need sampfuncs for it!
Well... poor explained and no screenshot/video.. I don't get what you mean nor what you need. Show a video of the process and more detailed of what the script it's supposed to do as well as what you already have of the script.
This is a snippet of how u can test if player is online. It will test if it is connected and if it is, it will add 1@ which is an integer and can be showed as 'chatmsg "%d" 1@'
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...
You just said 'whats wrong here'.. explain your script and what its supposed to do as well as bring video / screenshot to make thing clearer to what you're trying to do.
@Zin why does it not work for me?? i use sampfuncs 5.4.1 and cleo 4.1.. it doesn't work and i'm not sure what's wrong.. It simply doesn't say anything then after 10-15 seconds it reconects me to the server..
There is another route recorder that would probably help you but be careful!! With the helicopter it will move without leaning and u will get suspected of cheating as well for boats!! Planes are the only things you could hardly use.. pay attention to how the server reacts to this mod.
Check if each player from the server is driving and get the car id. Then get the car that you are in. Finally compare if your car matches with any that the other players drive.
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?
This is the problem. MODS ARE NOT ALL COMPATIBLE WITH LATEST CLEO / SAMPFUNCS. Most of the existing mods werent made for the latest cleo / sampfuncs versions. Using the latest versions its a HUGE mistake. I use sampfuncs 5.4.1 and cleo 4.1 and everything works perfect. Try use these and it might...
Reinstalling all GTA isnt that hard. You just need to copy and paste cleo and sampfuncs folders. Dont use latest sampfuncs / cleo, the version of sampfuncs / cleo might be the problem. Try using cleo 4.1 and sampfuncs 5.4.1, those are the one i use and everything works well. Old scripts such as...
Uh...theres a lot wrong with this code.. ill tell u the steps, u make them
1. Allocate memory
2. Get chat string, you only need text so for the other ones put the value as 0
3. Use 0ad4 (i think) to scan for the name, if the condition is met then go to step 4
4. You already have the player...
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...
You are wasting variables... Instead of using boolean (True / False) use integers (1, 2, 3 etc.). This will allow you to use a variable many times.. If 0@ == 1 then do one thing.. if 0@ == 2 then do another thing and so on.. you only have 31 variables which might not be enough for you.. 'Think...
Ok so i realised my variables are wrong. { 0AD4: $NOT_USED = scan_string 10@ format "Your friend %s is now online." 5@ } It's supposed to be scan_string 28@ however something is still wrong. Whenever a player is connected, it says (null), so i'm guessing it still has to do with 0AD4.
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.