Jump to content

BrianDUTCH

Members
  • Posts

    36
  • Joined

  • Last visited

Everything posted by BrianDUTCH

  1. Hello, I need help with a export to get Exp by getting a cashbox.. Levelsystem serverside code: function setExp(playerS,name,amount) local player = getPlayerFromName(name) local account = getPlayerAccount(playerS) local accName = getAccountName(account) if isObjectInACLGroup("user."..accName,aclGetGroup("Admin")) then if getElementType(player) == "player" and tonumber(amount) then setElementData(player,"kill.level",getElementData(player,"kill.level") + amount) outputChatBox("Your Experience level was increased by "..getPlayerName(playerS).." ("..amount.."%)",player,0,255,0) outputChatBox(getPlayerName(player).."'s Experience level was increased.",playerS,0,255,0) else outputChatBox("Failed to give because the player/amount was wrong.",playerS,255,255,0) end end end addCommandHandler("setExp",setExp,false,false) cashbox code after take CB: addEventHandler("onPickupHit", root, function(player) if source == bag then if getElementType(player) == "player" then if isPedInVehicle(player) then return end destroyElement(bag) randomCash = math.random(10000, 100000) randomArmour = math.random(5, 50) exports.levelsystem:setExp (getPlayerName(playerS), getPlayerFromName, math.random (8) ) outputChatBox("You have found $"..tostring(randomCash)..", "..tostring(randomArmour).."% Armour", player, 0, 255, 0) givePlayerMoney(player, randomCash) setPedArmor(player, getPedArmor(player) + randomArmour) destroyElement(bagBlip) setTimer(createMysteryBag, 1000, 1) end end end ) error: cashbox\mbag_s.lua:40: call: failed to call 'levelsystem:setExp' ][string"?"] I'm using this level system: https://community.multitheftauto.com/index.php?p=resources&s=details&id=11050 Cashbox : https://community.multitheftauto.com/index.php?p=resources&s=details&id=11612
  2. Only checking the topic won't help me guys.. please support me in this !!
  3. Anubhav, I still have the same error..
  4. Hello ! I made a CJ Customize GUI only I want to upgrade it, I need some help with it and I have 1 error but I don't know what the problem is.. The GUI looks like this now: Screenshot The Error = ERROR: CJ/customizeCJ-s.lua:18: attempt to index field '?' (a nil value) The error appears when I press on the save button.. I want to upgrade the following thing: The Editbox will be read only if the buttons < and > works. When I would press on the button > I want that the ID go higher so, 1,2,3,4 etc. and when I press it, it must set my new shirt for example.. button < must go down.. so 4,3,2,1,0 Need more info about the idea please just ask I want to fix it.. it will be a public resource to download on community ! Client function activateMenu ( player, key ) if (mainWindow) then guiSetVisible ( mainWindow, true ) else mainWindow = guiCreateWindow(0, 0, 280, 528, "CJ Customize", false) guiCreateLabel(10, 29, 64, 20, "Torso", false, mainWindow) guiCreateLabel(10, 54, 64, 20, "Hair", false, mainWindow) guiCreateLabel(10, 80, 64, 20, "Legs", false, mainWindow) guiCreateLabel(10, 106, 64, 20, "Shoes", false, mainWindow) guiCreateLabel(10, 132, 89, 20, "Left Upper Arm", false, mainWindow) guiCreateLabel(10, 158, 89, 20, "Left Lower Arm", false, mainWindow) guiCreateLabel(10, 184, 93, 19, "Right Upper Arm", false, mainWindow) guiCreateLabel(10, 208, 93, 19, "Right Lower Arm", false, mainWindow) guiCreateLabel(10, 233, 93, 19, "Back Top", false, mainWindow) guiCreateLabel(10, 258, 93, 19, "Left Chest", false, mainWindow) guiCreateLabel(10, 283, 93, 19, "Right Chest", false, mainWindow) guiCreateLabel(10, 308, 93, 19, "Stomach", false, mainWindow) guiCreateLabel(10, 333, 93, 19, "Lower Back", false, mainWindow) guiCreateLabel(10, 358, 93, 19, "Necklace", false, mainWindow) guiCreateLabel(10, 383, 93, 19, "Watch", false, mainWindow) guiCreateLabel(10, 408, 93, 19, "Glasses", false, mainWindow) guiCreateLabel(10, 433, 93, 19, "Hat", false, mainWindow) guiCreateLabel(10, 458, 93, 19, "Suit", false, mainWindow) button1 = guiCreateButton(154, 29, 24, 19, "<", false, mainWindow) button2 = guiCreateButton(154, 54, 24, 19, "<", false, mainWindow) button3 = guiCreateButton(154, 80, 24, 19, "<", false, mainWindow) button4 = guiCreateButton(154, 106, 24, 19, "<", false, mainWindow) button5 = guiCreateButton(154, 132, 24, 19, "<", false, mainWindow) button6 = guiCreateButton(154, 158, 24, 19, "<", false, mainWindow) button7 = guiCreateButton(154, 184, 24, 19, "<", false, mainWindow) button8 = guiCreateButton(154, 208, 24, 19, "<", false, mainWindow) button9 = guiCreateButton(154, 233, 24, 19, "<", false, mainWindow) button10 = guiCreateButton(154, 258, 24, 19, "<", false, mainWindow) button11 = guiCreateButton(154, 283, 24, 19, "<", false, mainWindow) button12 = guiCreateButton(154, 308, 24, 19, "<", false, mainWindow) button13 = guiCreateButton(154, 333, 24, 19, "<", false, mainWindow) button14 = guiCreateButton(154, 358, 24, 19, "<", false, mainWindow) button15 = guiCreateButton(154, 383, 24, 19, "<", false, mainWindow) button16 = guiCreateButton(154, 408, 24, 19, "<", false, mainWindow) button17 = guiCreateButton(154, 433, 24, 19, "<", false, mainWindow) button18 = guiCreateButton(154, 458, 24, 19, "<", false, mainWindow) button19 = guiCreateButton(241, 29, 24, 19, ">", false, mainWindow) button20 = guiCreateButton(241, 54, 24, 19, ">", false, mainWindow) button21 = guiCreateButton(241, 80, 24, 19, ">", false, mainWindow) button22 = guiCreateButton(241, 106, 24, 19, ">", false, mainWindow) button23 = guiCreateButton(241, 132, 24, 19, ">", false, mainWindow) button24 = guiCreateButton(241, 158, 24, 19, ">", false, mainWindow) button25 = guiCreateButton(241, 184, 24, 19, ">", false, mainWindow) button26 = guiCreateButton(241, 208, 24, 19, ">", false, mainWindow) button27 = guiCreateButton(241, 233, 24, 19, ">", false, mainWindow) button28 = guiCreateButton(241, 258, 24, 19, ">", false, mainWindow) button29 = guiCreateButton(241, 283, 24, 19, ">", false, mainWindow) button30 = guiCreateButton(241, 308, 24, 19, ">", false, mainWindow) button31 = guiCreateButton(241, 333, 24, 19, ">", false, mainWindow) button32 = guiCreateButton(241, 358, 24, 19, ">", false, mainWindow) button33 = guiCreateButton(241, 383, 24, 19, ">", false, mainWindow) button34 = guiCreateButton(241, 408, 24, 19, ">", false, mainWindow) button35 = guiCreateButton(241, 433, 24, 19, ">", false, mainWindow) button36 = guiCreateButton(241, 458, 24, 19, ">", false, mainWindow) editA = guiCreateEdit(182, 29, 55, 19, "0", false, mainWindow ) editB = guiCreateEdit(182, 54, 55, 19, "0", false, mainWindow ) editC = guiCreateEdit(182, 80, 55, 19, "0", false, mainWindow ) editD = guiCreateEdit(182, 106, 55, 19, "0", false, mainWindow ) editE = guiCreateEdit(182, 132, 55, 19, "0", false, mainWindow ) editF = guiCreateEdit(182, 158, 55, 19, "0", false, mainWindow ) editG = guiCreateEdit(182, 184, 55, 19, "0", false, mainWindow ) editH = guiCreateEdit(182, 208, 55, 19, "0", false, mainWindow ) editI = guiCreateEdit(182, 233, 55, 19, "0", false, mainWindow ) editJ = guiCreateEdit(182, 258, 55, 19, "0", false, mainWindow ) editK = guiCreateEdit(182, 283, 55, 19, "0", false, mainWindow ) editL = guiCreateEdit(182, 308, 55, 19, "0", false, mainWindow ) editM = guiCreateEdit(182, 333, 55, 19, "0", false, mainWindow ) editN = guiCreateEdit(182, 358, 55, 19, "0", false, mainWindow ) editO = guiCreateEdit(182, 383, 55, 19, "0", false, mainWindow ) editP = guiCreateEdit(182, 408, 55, 19, "0", false, mainWindow ) editQ = guiCreateEdit(182, 433, 55, 19, "0", false, mainWindow ) editR = guiCreateEdit(182, 458, 55, 19, "0", false, mainWindow ) applyButton = guiCreateButton(40, 495, 79, 18, "Save", false, mainWindow ) guiSetProperty( applyButton, "HoverTextColour", "FF00FF00" ) exitButton = guiCreateButton(153, 495, 79, 18, "Exit", false, mainWindow ) guiSetProperty( exitButton, "HoverTextColour", "FFFF0000" ) end showCursor ( true ) end addCommandHandler ( "customize", activateMenu ) function clickedButtonCheck ( element ) if source == applyButton then incredibleTable = { --the order is mixed because i sorted GUI menu better than type listings in code [0] = { storedValue = guiGetText ( editA ) }, [1] = { storedValue = guiGetText ( editB ) }, [2] = { storedValue = guiGetText ( editC ) }, [3] = { storedValue = guiGetText ( editD ) }, [4] = { storedValue = guiGetText ( editE ) }, [5] = { storedValue = guiGetText ( editF ) }, [6] = { storedValue = guiGetText ( editG ) }, [7] = { storedValue = guiGetText ( editH ) }, [8] = { storedValue = guiGetText ( editI ) }, [9] = { storedValue = guiGetText ( editJ ) }, [10] = { storedValue = guiGetText ( editK ) }, [11] = { storedValue = guiGetText ( editL ) }, [12] = { storedValue = guiGetText ( editM ) }, [13] = { storedValue = guiGetText ( editN ) }, [14] = { storedValue = guiGetText ( editO ) }, [15] = { storedValue = guiGetText ( editP ) }, [16] = { storedValue = guiGetText ( editQ ) }, [17] = { storedValue = guiGetText ( editR ) }, } triggerServerEvent ( "applyClothes", localPlayer, incredibleTable ) elseif source == exitButton then guiSetVisible ( mainWindow, false ) showCursor ( false ) end end addEventHandler ( "onClientGUIClick", root, clickedButtonCheck ) Server function applyClothing ( incredibleTable ) if getElementModel ( source ) ~= 0 then setElementModel ( source, 0 ) end count = 0 while count ~= 18 do if tostring(incredibleTable[count].storedValue) == "0" then removePedClothes ( source, count ) elseif tostring(incredibleTable[count].storedValue) ~= "" then --blank fields do nothing texture, model = getClothesByTypeIndex ( count, tostring(incredibleTable[count].storedValue) ) addPedClothes ( source, texture, model, count ) --outputChatBox ( "texture: "..texture.." model: "..model.." count: "..count ) end count = count + 1 end if tostring(incredibleTable[18].storedValue) ~= "" then setPedStat ( source, 21, incredibleTable[18].storedValue ) --outputChatBox ( "Fat stuff triggered" ) end if tostring(incredibleTable[19].storedValue) ~= "" then setPedStat ( source, 23, incredibleTable[19].storedValue ) --outputChatBox ( "Strong stuff triggered" ) end end addEvent("applyClothes", true, "incredibleTable" ) addEventHandler("applyClothes", root, applyClothing)
  5. hmm, u can change rhino color only by a mod as I know.. if u want change all vehicle color's to 1 special color you should use setVehicleColor
  6. This would work better to download vehicle mods I should say use gtainside, For example you can use this Rhino mod. Then make a script: function ReplaceVehicle ( ) outputChatBox ( "> replacing the rhino vehicle" ) txd = engineLoadTXD ( "rhino.txd" ) engineImportTXD ( txd, 432) dff = engineLoadDFF ( "rhino.dff", 0 ) engineReplaceModel ( dff, 432) end addEvent ( "replaceVeh", true ) addEventHandler ( "replaceVeh", getRootElement(), ReplaceVehicle )
  7. as I know that isn't possible on a rhino with setVehicleColor I think you should use mods try to use engineReplaceModel
  8. Thanks for help IIYAMA, it works good. I use the simple respawnVehicle now thanks.
  9. I have a another problem, I made the value's of respawn time in settings. But when I change the time in-game settings to 1 second then it doesn't work it still respawn every 15 seconds. please help ! Meta.xml removed removed Please help ! EDIT: SOLVED
  10. As u see the code above it works fine it respawn when it drown, but it also respawn when a player is inside the car how can I stop that? If players are in the car I don't want it respawn only when nobody is in the car !
  11. I tried to do this but it didn't work.. maybe I don't know the code.. I am newbie in lua
  12. Hello all , I can't figure out how to respawn the vehicle when it is drowned.. I added respawn vehicle if it has been idle for 5 minutes, and after blow up it respawns.. But I need help to make the vehicle respawn when it drown.. Hope u guys can help me !
  13. BrianDUTCH

    MTA crashing

    Here MTADiag http://pastebin.mtasa.com/322525699
  14. BrianDUTCH

    MTA crashing

    I start up MTA, It shows; Stop playing with yourself. after that it stops nothing happens more.. please help .. ------------------ System Information ------------------ Time of this report: 5/12/2014, 18:41:00 Machine name: ANCHES-PC Operating System: Windows 7 Home Premium 64-bit (6.1, Build 7601) Service Pack 1 (7601.win7sp1_gdr.130828-1532) Language: Dutch (Regional Setting: Dutch) System Manufacturer: Acer System Model: Aspire M3400 BIOS: Default System BIOS Processor: AMD Athlon(tm) II X4 635 Processor (4 CPUs), ~2.9GHz Memory: 4096MB RAM Available OS Memory: 3832MB RAM Page File: 3374MB used, 4286MB available Windows Dir: C:\Windows DirectX Version: DirectX 11 DX Setup Parameters: Not found User DPI Setting: Using System DPI System DPI Setting: 96 DPI (100 percent) DWM DPI Scaling: Disabled DxDiag Version: 6.01.7601.17514 32bit Unicode ------------ DxDiag Notes ------------ Display Tab 1: No problems found. Sound Tab 1: No problems found. Sound Tab 2: No problems found. Input Tab: No problems found. -------------------- DirectX Debug Levels -------------------- Direct3D: 0/4 (retail) DirectDraw: 0/4 (retail) DirectInput: 0/5 (retail) DirectMusic: 0/5 (retail) DirectPlay: 0/9 (retail) DirectSound: 0/5 (retail) DirectShow: 0/6 (retail) --------------- Display Devices --------------- Card name: Standaard-VGA grafische adapter Manufacturer: (Standaardbeeldschermtypen) Chip type: ATI display adapter (0x9715) DAC type: Internal DAC(400MHz) Device Key: Enum\PCI\VEN_1002&DEV_9715&SUBSYS_04441025&REV_00 Display Memory: 256 MB Dedicated Memory: n/a Shared Memory: n/a Current Mode: 1024 x 768 (32 bit) (1Hz) Monitor Name: Algemeen PnP-beeldscherm Monitor Model: Monitor Id: Native Mode: Output Type: Driver Name: vga.dll,framebuf.dll,vga256,vga64k Driver File Version: 6.01.7600.16385 (Dutch) Driver Version: 6.1.7600.16385 DDI Version: unknown Driver Model: Onbekend Driver Attributes: Final Retail Driver Date/Size: 7/14/2009 01:38:47, 15360 bytes WHQL Logo'd: Yes WHQL Date Stamp: Device Identifier: {D7B71EE2-D455-11CF-9433-F439AEC2CB35} Vendor ID: 0x1002 Device ID: 0x9715 SubSys ID: 0x04441025 Revision ID: 0x0000 Driver Strong Name: Unknown Rank Of Driver: Unknown Video Accel: Deinterlace Caps: n/a D3D9 Overlay: n/a DXVA-HD: n/a DDraw Status: Not Available D3D Status: Not Available AGP Status: Not Available ------------- Sound Devices ------------- Description: Speakers (Realtek High Definition Audio) Default Sound Playback: Yes Default Voice Playback: Yes Hardware ID: HDAUDIO\FUNC_01&VEN_10EC&DEV_0662&SUBSYS_10250444&REV_1001 Manufacturer ID: 1 Product ID: 100 Type: WDM Driver Name: RTKVHD64.sys Driver Version: 6.00.0001.6024 (English) Driver Attributes: Final Retail WHQL Logo'd: Yes Date and Size: 1/12/2010 12:14:32, 2239136 bytes Other Files: Driver Provider: Realtek Semiconductor Corp. HW Accel Level: Basic Cap Flags: 0xF1F Min/Max Sample Rate: 100, 200000 Static/Strm HW Mix Bufs: 1, 0 Static/Strm HW 3D Bufs: 0, 0 HW Memory: 0 Voice Management: No EAX(tm) 2.0 Listen/Src: No, No I3DL2(tm) Listen/Src: No, No Sensaura(tm) ZoomFX(tm): No Description: Realtek Digital Output (Realtek High Definition Audio) Default Sound Playback: No Default Voice Playback: No Hardware ID: HDAUDIO\FUNC_01&VEN_10EC&DEV_0662&SUBSYS_10250444&REV_1001 Manufacturer ID: 1 Product ID: 100 Type: WDM Driver Name: RTKVHD64.sys Driver Version: 6.00.0001.6024 (English) Driver Attributes: Final Retail WHQL Logo'd: Yes Date and Size: 1/12/2010 12:14:32, 2239136 bytes Other Files: Driver Provider: Realtek Semiconductor Corp. HW Accel Level: Basic Cap Flags: 0xF1F Min/Max Sample Rate: 100, 200000 Static/Strm HW Mix Bufs: 1, 0 Static/Strm HW 3D Bufs: 0, 0 HW Memory: 0 Voice Management: No EAX(tm) 2.0 Listen/Src: No, No I3DL2(tm) Listen/Src: No, No Sensaura(tm) ZoomFX(tm): No --------------------- Sound Capture Devices --------------------- Description: Microfoon (HP Webcam HD-2200) Default Sound Capture: Yes Default Voice Capture: Yes Driver Name: USBAUDIO.sys Driver Version: 6.01.7601.18208 (English) Driver Attributes: Final Retail Date and Size: 7/12/2013 12:40:58, 109824 bytes Cap Flags: 0x1 Format Flags: 0xFFFFF ------------------- DirectInput Devices ------------------- Device Name: Muis Attached: 1 Controller ID: n/a Vendor/Product ID: n/a FF Driver: n/a Device Name: Toetsenbord Attached: 1 Controller ID: n/a Vendor/Product ID: n/a FF Driver: n/a Device Name: USB Multimedia Keyboard Attached: 1 Controller ID: 0x0 Vendor/Product ID: 0x04CA, 0x002F FF Driver: n/a Device Name: USB Multimedia Keyboard Attached: 1 Controller ID: 0x0 Vendor/Product ID: 0x04CA, 0x002F FF Driver: n/a Device Name: USB Multimedia Keyboard Attached: 1 Controller ID: 0x0 Vendor/Product ID: 0x04CA, 0x002F FF Driver: n/a Poll w/ Interrupt: No ----------- USB Devices ----------- + USB-hoofdhub | Vendor/Product ID: 0x1002, 0x4397 | Matching Device ID: usb\root_hub | Service: usbhub ---------------- Gameport Devices ---------------- ------------ PS/2 Devices ------------ + HID-toetsenbordapparaat | Vendor/Product ID: 0x04CA, 0x002F | Matching Device ID: hid_device_system_keyboard | Service: kbdhid | + Toetsenbordstuurprogramma voor Terminal Server | Matching Device ID: root\rdp_kbd | Upper Filters: kbdclass | Service: TermDD | + HID-muis | Vendor/Product ID: 0x046D, 0xC054 | Matching Device ID: hid_device_system_mouse | Service: mouhid | + Muisstuurprogramma voor Terminal Server | Matching Device ID: root\rdp_mou | Upper Filters: mouclass | Service: TermDD ------------------------ Disk & DVD/CD-ROM Drives ------------------------ Drive: C: Free Space: 118.3 GB Total Space: 230.4 GB File System: NTFS Model: WDC WD5000AAKS-22V1A SCSI Disk Device Drive: D: Free Space: 210.5 GB Total Space: 231.1 GB File System: NTFS Model: WDC WD5000AAKS-22V1A SCSI Disk Device Drive: Q: Model: n/a Drive: E: Model: HL-DT-ST DVDRAM GH60N SCSI CdRom Device Driver: c:\windows\system32\drivers\cdrom.sys, 6.01.7601.17514 (Dutch), , 0 bytes -------------- System Devices -------------- Name: PCI standard host CPU bridge Device ID: PCI\VEN_1022&DEV_1201&SUBSYS_00000000&REV_00\3&267A616A&0&C1 Driver: n/a Name: Standard OpenHCD USB Host-controller Device ID: PCI\VEN_1002&DEV_4397&SUBSYS_04441025&REV_00\3&267A616A&0&98 Driver: n/a Name: High Definition Audio-besturing
  15. Here is the MTAdiag http://pastebin.mtasa.com/543125947 Please help.. I try to open MTASERVER.exe and it stops directly.. What to do ? Help me
  16. Yes, but I bought a new video card. It's working now! No crashes anymore FPS from 20 to 90 !
  17. Where is this? Remove the side panel from your computer
×
×
  • Create New...