bandi94
Members-
Posts
1,037 -
Joined
-
Last visited
Everything posted by bandi94
-
Well , toJSON / fromJSON will work until you hit the MTA account data string lenght limit. It's around 100 char.
-
Pitch / Yaw ( Y , Z ) roation is prity simple to calculate It's not coded in LUA , it's C++ , i just C+P it from my old aimbot used in some FPS game's , but the math is the same just need to be recoded to LUA. D3DXVECTOR3 NewVector; NewVector.x = pClientInfo->g_pLocal->Pos.x - g_pESP.pPlayers[AimAt].Aimcords.x; NewVector.y = pClientInfo->g_pLocal->Pos.y - g_pESP.pPlayers[AimAt].Aimcords.y; NewVector.z = pClientInfo->g_pLocal->Pos.z - g_pESP.pPlayers[AimAt].Aimcords.z; float CamYaw = (float)atanf(NewVector.x/NewVector.z); if(NewVector.z > 0.0f && NewVector.x < 0.0f && CamYaw < 0.0f) CamYaw += D3DX_PI; else if(NewVector.z > 0.0f && NewVector.x > 0.0f) CamYaw += D3DX_PI; DWORD tempKey = 0; switch(AimbotKey) { default: tempKey = VK_LBUTTON; break; case 1: tempKey = VK_RBUTTON; break; case 2: tempKey = VK_SHIFT; break; } if((GetAsyncKeyState(tempKey) && !Aimbotkeyon) || (Aimbotkeyon)) { pClientInfo->g_pLocal->pitch = (float)atan2f(NewVector.y,(float)sqrt(pow(NewVector.z,2) + pow(NewVector.x,2))); pClientInfo->g_pLocal->yaw = CamYaw;
-
Well yes. I disabled the collision (it's not race gamemode , it's a gamemode made by me ) i used on client side "setElementCollidableWith" and when 2 player's (in car) go very close / they are on each other , the camera will zoom to my car. I used it on client side bk , some player's need to collide with some player's and not collide with other player's . Normal Camera : Collision off and 2 player on each other:
-
Yes. MySQL and SQLite string's are the same.
-
Ok. but if i wanna make it from Point1 to Point2 : where Point1 is with 45 degree rotation from Point2. It's impossible to do it with Rectangel.
-
if you want to make it from point1 to pint2 https://wiki.multitheftauto.com/wiki/CreateColPolygon http://en.wikipedia.org/wiki/Polygon if you wanna make a cube or rectangel in point1 and point2 https://wiki.multitheftauto.com/wiki/CreateColRectangle also you can add in the code : "setDevelopmentMode(true)" and then in chatBox wirte "/showcol 1" then you will see the ColShape ingame
-
using "tocolor" on DxDraw. tocolor has 4 arguments RGBA where A is alpha 0-255. local fade_a local do_fade function dxDraw ( ) DxDrawRectangle(0,0,100,100,tocolor(0,0,0,fade_a)) if do_fade then -- if fade is enabled fade_a = fade_a - 1 -- decrease alpha on every frame until is 0 end if do_fade and fade_a <=0 then -- if fade alpha is 0 turn the DxDraw off removeEventHandler("onClientRender",root,dxDraw) end end addEvent( "dxDraw", true ) addEventHandler( "dxDraw", root, function() fade_a = 255 -- set alpha to max. do_fade = false -- set fade effect off addEventHandler("onClientRender",root,dxDraw) setTimer(function() do_fade = true end ,10000,1) -- after 10s enable fade end )
-
Server function buyMsg (player) if showRoomVehicles[source] then setVehicleLocked ( source, true ) triggerClientEvent (player, "dxDraw", player ) end end Client function dxDraw ( ) DxDrawRectangle(0,0,100,100) end addEvent( "dxDraw", true ) addEventHandler( "dxDraw", root, function() addEventHandler("onClientRender",root,dxDraw) setTimer(function() removeEventHandler("onClientRender",root,dxDraw) end ,3000,1) end ) it will Draw the Rectangel for 3 secounds
-
When running play / other gamemode , and using GhostMode when 2 player's are (almost) on each other (with car) the camera will zoom in. But in Race somehow this effect is kill'd / turned of so the camera will not zoom in when you are on top of other player. I searched in the race where/ how it's made but i dont find it , anyobody have any idea how it's made ?
-
.Fx is used for shader's. Yes it's a scripting language (using DirectX) well you can use almost any text editor to open/edit/make one .fx file. One recommendation would be "Notepad++".
-
Nope let me explain. I am rescripting the TopTime's , to don't lose the old time's i will use the race_toptimes system . To show the first top 10 time's without use table / sort i use "ORDER BY timeMs ASC LIMIT 10" -- this will return 10 row's the row's are already sorted bk of the "ORDER BY timeMs ASC" command. Now on the last line of the topTime i wanna , show the player's rank (if you are not in top10 then on the last line will show "Top 25 - Yourname" , now to search the player's rank i will use the playerSerial column(race_toptime's already saved the playerSerial for all time's) so to do this i will need to get all time's in a tabel then use table.sort then loop trough and mach the serial if i found a mach it mean's that the top time is from that player. I wanna cut off the table.sort , and use SQLite command to do that. (the SQLite SelectCommand would return the rank) Example: PlayerName1 1.30 PlayerName2 1.45 .......... Now let's say i am PlayerName1 , and i am rank 2 , to find out this thing i would need to use table.sort , but i am woundering if SLQlite could do this for me like. "Select * Where playerSerial=? RETURN ORDER BY timeMs ASC" -- and this would return the data + number"2" from command "RETURN" bk "ORDER BY timeMs ASC" + "WHERE" command , would find me as TOP2 By timeMs
-
I am using SQLite , to store some topTime's. ATM i am using 'ORDER BY timeMs ASC LIMIT 10' to get the first TOP 10 time's without putt all row's in a table and use sort. Now i wanna use "Select..... Where playerSerial=?" and get the rank for that player by the timeMs column without load all row's in a table , sort it , and search for the Serial then the rank would be "i". Something like : Select..... Where playerSerial=? RETURN ORDER BY timeMs ASC" Is it possbile with some SQLite command (assuming that the row's are not ordered by the TimeMs column) ?
-
Well yah , that's the point , but i was unable to find any Online Converter , that could be used with calling it from other php. There are only "paste the link and press the download button" well maybe it's possbile to do it i am prity noob at php/html . BTW : yes i think he wanna enter the youtube : link , then MTA would play the song (atleast i wanted to do this)
-
@NssoR please realy stop posting more crap , bk i will end dead from laughing. Youtube it's not using .mp3 format how dafu*** you wanna change the "formula" of this video "https://www.youtube.com/watch?v=eaTawbEn_d4" to mp3 "formula" and play it on the server. ? We area speaking about real time youtube converter , i enter a song name on the server then : server->php->youtube->mp3 converter -> php -> server -> client -> playSound. And not about download some song from youtube and put it in the server.
-
Well , i was searching some time ago for this. Yes it's possbile , by convert the youtube video to mp3 then play/download it to the client. There are page's like this ("youtube to mp3") , but i don't find any one that could be used with php call on server request. So i started searching for project's / php's that could be used , well that was a dead end to , bk all i found it was some pay'd stuff's .So i give'd up on this.
-
Alright..about the script i use atm...can you fix the error? I already told you what's the problem even if that is not the problem , the player's will very fast reach +100char string to save in that moment the script will fail , bk it's not possbile to save it on accountData.
-
The server was Off , and after i restarted many time's but still don't work. I tryed to copy the .db's to my localhost server and it's working. So i made a small test registred new account and opened the database. The host is using some other PW saving system. My old Pw's are long and upper case , the new PW's (register) are more shorter (1/4) and lower case (it's MD5 ) .
-
I moved my server to other host bk of some problem's with the old one. I saved the "internal/registry.db" , deleted the empty one from the new server and copy'ed the old one , to keep all the account's / top time's , etc.... And a funny thing apeard , when i try to login it's say's invalid pasword for account ...... , if i try to register again with the same name then it's say's account already in use, so the account's are loaded but on login it's say's wrong pw. What's the problem ?
-
for i,v in pairs(table) do -- Your stuff if i == 10 then break end end
-
AccountData has it's own limit of char's it's around 100. If your "weaponStats" string is bigger that +100 char's the end of the string will not be saved =>> split will retunr nil.
-
"setAccountData" has a limit of (i am not shure) but it's somewhere around 100 char's. So maybe @TAPL tryed with one clothe , but when you add more clothes the save will fail bk the larger char count.
-
Some player's say'd that they are keep getting some kind of Joining Flood error when they try to join. Well i can join and other's to , and i never heard about this error. Is this something about the server , or is from the player's PC ? They tryed to reinstal MTA but the same thing. ??
-
and designing the camera to the front of the player, so we will not see it, is that possible? Yes that is possible. getCameraMatrix setCameraMatrix "onClientPreRender"