Jump to content

manve1

Retired Staff
  • Posts

    1,283
  • Joined

  • Last visited

Everything posted by manve1

  1. https://wiki.multitheftauto.com/wiki/Scr ... troduction
  2. That's the LOD, when you hover with your mouse over the object you will see the Object id and LOD Id, remove both of them and you will have no problem
  3. manve1

    shaders help

    MTA is GTA, just multiplayer. If you have the shader, learn how to program in lua.
  4. No problem, but study what i have changed and what I've kept.
  5. Take a look at the difference between the codes (test my code and check if that is what you wanted, if it is then go to wiki and read about the functions). Your client side: GUIEditor = { button = {}, window = {}, memo = {} } function initGUI( ) btnOutput = guiCreateButton(65, 102, 219, 21, "Buy Advert!", true) addEventHandler ("inClientGUIClick", btnOutput, outputEditBox, false ) editBox=guiCreateEdit(20, 38, 304, 58, "Type your advert here", true) guiEditSetMaxLength ( editBox, 30 ) end addEventHandler("onClientResourceStart", getResourceRootElement( getThisResource()),initGUI ) function outputEditBox ( button ) if button = "left" then local text = guiGetText ( editBox ) outputChatBox ( text ) end end function() GUIEditor.window[1] = guiCreateWindow(455, 192, 343, 133, "Advert cost 500. Click button below to buy it!", false) guiWindowSetSizable(GUIEditor.window[1], false) guiSetAlpha(GUIEditor.window[1], 1.00) GUIEditor.memo[1] = guiCreateMemo(20, 38, 304, 58, "", false, GUIEditor.window[1]) btnOutput = guiCreateButton(65, 102, 219, 21, "Buy Advert!", true) guiSetFont(GUIEditor.button[1], "default-bold-small") end ) Your server side: function Advertisment(thePlayer, commandName, ...) local players = getElementsByType("player") local playerName = getPlayerName ( thePlayer ) local chatContent = {...} for index, player in ipairs ( players ) do outputChatBox( "Advertisment from " .. playerName.. ": " ..table.concat ( chatContent, " "), player, 0, 190, 40) end end addCommandHandler( "ad", Advertisment ) My client side: function GUI() Window = guiCreateWindow(455, 192, 343, 133, "Advert costs 500. Click the button below to buy it!", false) guiWindowSetSizable(Window, false) guiSetAlpha(Window, 1.00) Memo = guiCreateMemo(20, 38, 304, 58, "", false, Window) Button = guiCreateButton(65, 102, 219, 21, "Buy Advert!", false, Window) guiSetFont(Button, "default-bold-small") showCursor(true) addEventHandler("onClientGUIClick",Button,buttonClick,false) end addCommandHandler("ad",GUI) function buttonClick() if getPlayerMoney(localPlayer) >= 500 then local memoText = guiGetText(Memo) triggerServerEvent("AD",localPlayer,localPlayer,memoText) guiSetVisible(Window,false) showCursor(false) else outputChatBox("#0000FF[AD]#00FF00 You need more money.",0,255,0,true) end end My server side: addEvent("AD",true) addEventHandler("AD",getRootElement(), function (p,text) setPlayerMoney(p,getPlayerMoney(p)-500) outputChatBox("#0000FF[AD] #FFFFFF"..getPlayerName(p)..": #00FF00"..text,root,0,255,0,true) end )
  6. I can't be elected because I'm not a Pakastani. By what's written in the main post, it doesn't state that you MUST be Pakistani to get nominated, all you have to know is Urdu Language.
  7. manve1

    enb link help

    Even if you have the FX Shaders, you still need to know functions from MTA to implement it. Here's the start: LINK
  8. For a piece like that which would most probably include creating images on Ai or Ps, that budget is seriously low. I would recommend you at least get 20-30€ to start trying to discus something like that.
  9. I'm not trying to be funny or disrespectful, but form other posts you made it looks like you're new to MTA scripting, I wouldn't recommend going from LUA to HLSL as LUA isn't as complicated as HLSL is and for the fact, you need to know both of them to make shaders like GTA V has.
  10. first it's motion. second the slow motion would have to be through out the server as if it was client the player is slowed down but someone just shoots him/her in the head easily and because it has to be server sided, someone will just have the key held for a long time and if you add a timer to stop slow motion after a certain time, he/she can just simply re-hit it, or use a program that would do it for him/her and just go somewhere. As for the hud payment, what is your budget? If your budget is low, good luck. Otherwise you can create it yourself by creating pictures of weapons, and the hud background. place the images in an orientation that would be the same as GTA V has and when a player changes what gun he wants check which image it is and give him the correct gun.
  11. Server side 2 script should be: exports.scoreboard:addScoreboardColumn("Rank",getRootElement(),1,40,"Rank") function scoreLevel () local account = getPlayerAccount(source) local icon = tonumber(getAccountData(account,"icon")) or "1" if isGuestAccount ( account ) then setElementData(source, "Rank",":myranks/img/1.png") else setElementData(source, "Rank", ":myranks/img/"..tostring(icon)..".png" ) end end addEventHandler("onPlayerSpawn", getRootElement(), scoreLevel)
  12. This reminds me of GTA 5, although the grass ruins it. Well done.
  13. you can loop images to make a gif, yes it's additional effort, but still it can be done using the formats currently given, so no point really except to reduce code in your own script.
  14. Not a lot of people will have a free laying script like this and to this, not a lot of people would script this. I suggest it that if you want to get a hand on TTT scripts, get some budget as people these days only get involved when there is talk about dosh.
  15. Edit them, i don't think so, but you could re-draw the location names with your own input.
  16. To add the button in F1, it would mean you would need to re-script the freeroam resource ( i don't know which file it is ), but here are some functions that you could use/learn. guiCreateButton addEventHandler toggleControl cancelEvent events for use: onClientGUIClick onClientPlayerDamage There are different ways to make it, but using these functions/event it's the easiest (in my opinion of course) [You will need if statements to toggle it back on and variables.]
  17. Well, it's simple (if you want it to be in the server). Create a new function On functions execution you prevent any keys on pressing (except keys like esc, ctrl ...) Draw some text explaining why When clicked on "OK" or something, he gets disconnected and added to banned list. On connect check if it's a banned serial, if it is, kick him. But if you want the original one to be changed, i am pretty sure it is possible, just take a look: kickPlayer ( player kickedPlayer, [ player responsiblePlayer, string reason = "" ] )
  18. That code is kind of useless, unless you use it for collecting data. But what you would have to do is either re-script the spawning system and do few tables instead of one, then spawn each area every second or so. or you have to collect data on which pickup it is spawning then you would allow it to refresh the loot or not + store the areas that are not been refreshed (this is a lot more complicated but is more elegant and faster)
  19. There are a lot of ways to optimize a script, for example you could load areas one by one, by that i mean lv is loaded at first, then ls and so on ..
  20. You'll need a shader, i told you, motion blur in vehicles is already implemented, but if you want a static or a motion blur, then you will need to get a shader, the best resource to edit is this: https://community.multitheftauto.com/index.php?p= ... s&id=10163
  21. You will need a shader.
×
×
  • Create New...