-
Posts
1,058 -
Joined
-
Last visited
-
Days Won
1
Posts posted by Saml1er
-
-
What is your MTA version? You can check it by writing "ver" in the F8 console.
Can you check for recent crash dumps in DRIVE:\Program Files (x86)\MTA San Andreas 1.5\MTA\dumps\private? If you do find new crash dumps, then please upload them to https://upload.mtasa.com and paste the link here (only MTA staff can access it).
- 1
-
23 hours ago, MRmihailZH said:
I tried your code and nothing happens. I tried to fix something and also all to no avail.
if (objectMovingTick - getTickCount()) < gateCommandWaitInMs then
I made a typo here. This should be:
if (getTickCount() - objectMovingTick) < gateCommandWaitInMs then
-
local gateCommandWaitInMs = 3000 -- 3000 milliseconds. You can increase or decrease this value to meet your requirements local objectMovingTick = getTickCount() + gateCommandWaitInMs -- we are adding this to tick, so we don't have to wait for 3 seconds in first use gateLSPD = false x, y, z = getElementPosition ( source ) if getDistanceBetweenPoints3D ( x, y, z, 1544.24707, -1631.90906, 13.38281 ) <= 2 then if (objectMovingTick - getTickCount()) < gateCommandWaitInMs then -- check if 3000 milliseconds have passed return end if gateLSPD == false then local rotX, rotY, rotZ = getElementRotation(shlagLSPD) moveObject ( shlagLSPD, 2000, 1544.6999511719, -1630.9000244141, 13.10000038147, 0, -80, 0 ) gateLSPD = true else local rotX, rotY, rotZ = getElementRotation(shlagLSPD) moveObject ( shlagLSPD, 2000, 1544.6999511719, -1630.9000244141, 13.10000038147, 0, 80, 0 ) gateLSPD = false end objectMovingTick = getTickCount() end
You can use getTickCount to fix the problem.
-
Nice work. We really need something like this.
-
On 04/02/2019 at 14:04, haron4igg said:
I want to replace crouch animations to let ped move naturally without additional scripting. We saw how original anims working.
Upload your resource to mediafire or google drive and post the link here.
-
4 hours ago, Cyber14 said:
I have no any problems with custom objects. I know It can be weird but I tested how long it takes to load objects with and without replacing models and it turned out that objects without replacing loaded faster
Can you post the script where you create the objects? I'd like to test it.
- 1
-
15 hours ago, iDannz said:
I have the same problem with custom objects too
createObject function executes pretty quickly. I think you're talking about engine functions, like engineLoadDFF, *TXD, and *COL.
-
So, you simply want the ability to shoot with a weapon when you are close to a wall or when a player is blocking you with his elbow? Currently, you can't do that. I can add this ability to:
setGlitchEnabled
Create a new issue on github and paste the link here.
-
Are those custom objects?
-
Open F8 > Write "ver" > Enter > copy-paste the build version here.
-
-
-
1 hour ago, mucuk6547 said:
It wasn't, but I want this animation to appear in everyone, it just seems to me, what should I do? Can you help.
Have you checked ifp_demo resource? animations are synced there.
-
2 hours ago, mucuk6547 said:
unfortunately I'm not getting anything
Copy-paste your meta.xml here. Also, make sure that rifle.ifp is located in the top directory of the resource.
-
Looks like a common crash, i.e., not enough memory.
-
-
It's going to be a lot of work. You have to manually convert the models to DFF, COL, and TXD files.
-
32 minutes ago, barras said:
but I didn't do anything wrong?
You did something. The anti-cheat detected a known trainer. Please follow these steps:
- 1
-
Delete all of your code from server.lua and client.lua. Copy-paste everything from ifp_demo and put this in client.lua at bottom of the file:
addEventHandler("onClientResourceStart", resourceRoot, function() local ifpIndex = 7 ReplacePedBlockAnimations ( localPlayer, ifpIndex ) triggerServerEvent ( "onCustomAnimationReplace", resourceRoot, localPlayer, ifpIndex ) end )
-
3 hours ago, greentumbleweed said:
my last question and the one i should have started with is what is "ifpIndex" is that the number or is that the block name
--TestaddEventHandler("onClientResourceStart", resourceRoot, function() startingAnimations() -- call the function end)function startingAnimations() ReplacePedBlockAnimations ( source, 7 )end --ENDReplacePedBlockAnimations ( player, ifpIndex )-- i do not understand i tried 7 and nothing happens, also tried "GTA IV" still nothing
"ifpIndex" is the index of the ifp file you want to load from globalLoadedIfps table, the table contains IFP data, like file path, new block name, the animations of the ifp file, etc.. Instead of sending an entire table via triggerServerEvent or triggerClientEvent which will use more internet bandwidth, we simply send an index of the required table for ifp which will be much faster. Also, can you please login as admin and execute /debugscript 3 on your server? It will show you errors within code on screen if there are any. Also, I just realized that source is also not defined here:
function startingAnimations() ReplacePedBlockAnimations ( source, 7 ) -- Where is source defined? It is not a predefined variable. end
Correction:
function startingAnimations() ReplacePedBlockAnimations ( localPlayer, 7 ) end
localPlayer is a predefined variable on client side. It will always be valid. localPlayer is YOU.
More about predefined variables: https://wiki.multitheftauto.com/wiki/Predefined_variables_list
-
7 hours ago, greentumbleweed said:
its at the bottom of the client
Nope. You have only defined the function, you never call it. It's like you sit in a vehicle with no driver and you expect it to magically take you to your destination, that won't happen. You have to drive the vehicle, in the same way, you have to call this function. You call the function like this:
startingAnimations()
Ok, calling this function before the download will not work because the IFP has not loaded, so we'll use an event for it. Put this code snippet at the bottom of client.lua:
addEventHandler("onClientResourceStart", resourceRoot, function() startingAnimations() -- call the function end )
-
Okay, I can see everything's right here. Now tell me where you are calling startingAnimations function? You have defined the function but you never call it anywhere within the code which means the code never executes.
-
26 minutes ago, greentumbleweed said:
so if i use ^ on client side will everything still be synchronize server side?
No, I was talking to NmLa. I asked you a question but you didn't respond:
12 hours ago, Saml1er said:where are you calling startingAnimations function? Also, can you show how globalLoadedIfps is defined?
-
2 hours ago, NmLa said:
is there are chance to add ninja's ifp for running?
You can load any IFP file that was created for GTA VC and SA using:
engineLoadIFP
So yes, you can load the ifp file to MTA if you have it.
- 1
Backdoors ban?
in Ban appeals archive
Posted
You were banned for sharing a leaked gamemode that contained backdoors. In fact, you were even threatening the server owner that you'll leak his server database and you were boasting about it on your discord. It's pretty clear that you knew what you were doing. Your ban is temporary, you'll have to wait for it to expire. Appeal denied.