undefined Posted March 29, 2014 Posted March 29, 2014 (edited) Hi Guys. Im create a mission system. Giving weapons at the end of the mission, but does not give exp. .... givePlayerMoney ( p, 25000,true ) giveWeapon(p,25,75,true) giveWeapon(p,24,250,true) local _, addexp = exports [ "Jack" ]:addPlayerExp ( exp ) if ( addexp ) then addPlayerExp (source, 353, true) end .... Jack\mission.lua:50: call: failed to call 'Jack:addPlayerExp' and give this error on Castillo's exp_system. Edited March 29, 2014 by Guest
Castillo Posted March 29, 2014 Posted March 29, 2014 Well, obviously it'll give errors, you didn't specify the player argument to which you want to give it. local _, addexp = exports [ "Jack" ]:addPlayerExp ( p, exp )
undefined Posted March 29, 2014 Author Posted March 29, 2014 (edited) Thank solid. But I've got a problem. Client-Side addEvent( "zorqrok" ,true) addEventHandler( "zorqrok" , getRootElement(), function send() local sWidth, sHeight = guiGetScreenSize() dxDrawRectangle(0, sHeight-29, sWidth, sHeight, tocolor(0, 0, 0, 150), true) yazi1 = dxDrawText("text zone", 0, sHeight-29, sWidth, sHeight, tocolor(255, 255, 255, 255), 1.00, "bankgothic", "center", "center", false, false, true, true, false) setTimer ( function() local sWidth, sHeight = guiGetScreenSize() destroyElement(yazi1) yazi2 = dxDrawText("text zone", 0, sHeight-29, sWidth, sHeight, tocolor(255, 255, 255, 255), 1.00, "bankgothic", "center", "center", false, false, true, true, false) end, 10000, 1 ) destroyElement(yazi2) end send() addEvent("gorevBitti",true) addEventHandler("gorevBitti", getRootElement(), function() gorevgrid = guiCreateGridList((sWidth/2)+(sWidth/4), (sHeight/2)+(sHeight/4), 301, 229, false) guiSetAlpha(gorevgrid, 0.65) tebrikler = guiCreateLabel(10, 10, 281, 37, "Congrulations", false, gorevgrid) local font_0 = guiCreateFont("fonts/bloody.ttf", 15) guiSetFont(tebrikler, font_0) guiLabelSetHorizontalAlign(tebrikler, "center", false) guiLabelSetVerticalAlign(tebrikler, "center") alacaklar = guiCreateLabel(10, 47, 281, 37, "You Will Get;", false, gorevgrid) guiSetFont(alacaklar, font_0) guiLabelSetHorizontalAlign(alacaklar, "center", false) guiLabelSetVerticalAlign(alacaklar, "center") odul1 = guiCreateLabel(10, 84, 281, 37, "25.000 $", false, gorevgrid) guiSetFont(odul1, font_0) guiLabelSetHorizontalAlign(odul1, "center", false) guiLabelSetVerticalAlign(odul1, "center") odul2 = guiCreateLabel(10, 121, 281, 37, "75 Shotgun - 250 Deagle", false, gorevgrid) guiSetFont(odul2, font_0) guiLabelSetHorizontalAlign(odul2, "center", false) guiLabelSetVerticalAlign(odul2, "center") odul3 = guiCreateLabel(10, 158, 281, 37, "and 350 exp!", false, gorevgrid) guiSetFont(odul3, font_0) guiLabelSetHorizontalAlign(odul3, "center", false) guiLabelSetVerticalAlign(odul3, "center") close = guiCreateButton(83, 199, 135, 20, "Close", false, gorevgrid) showCursor(true) playSound("gorev.mp3") end ) function Jose() if source == close then guiSetVisible ( gorevgrid,false ) showCursor( false ) end end addEventHandler("onClientGUIClick",root,Jose ) ) Server-Side ... triggerClientEvent(p, "zorqrok" , getRootElement()) ... Edited March 29, 2014 by Guest
WhoAmI Posted March 29, 2014 Posted March 29, 2014 addEventHandler( "zorqrok" , getRootElement(), function send() local sWidth, sHeight = guiGetScreenSize() dxDrawRectangle(0, sHeight-29, sWidth, sHeight, tocolor(0, 0, 0, 150), true) yazi1 = dxDrawText("text zone", 0, sHeight-29, sWidth, sHeight, tocolor(255, 255, 255, 255), 1.00, "bankgothic", "center", "center", false, false, true, true, false) setTimer ( function() local sWidth, sHeight = guiGetScreenSize() destroyElement(yazi1) yazi2 = dxDrawText("text zone", 0, sHeight-29, sWidth, sHeight, tocolor(255, 255, 255, 255), 1.00, "bankgothic", "center", "center", false, false, true, true, false) end, 10000, 1 ) destroyElement(yazi2) send() end )
Karuzo Posted March 29, 2014 Posted March 29, 2014 addEvent("zorqrok",true) function send() local sWidth, sHeight = guiGetScreenSize() dxDrawRectangle(0, sHeight-29, sWidth, sHeight, tocolor(0, 0, 0, 150), true) yazi1 = dxDrawText("text zone", 0, sHeight-29, sWidth, sHeight, tocolor(255, 255, 255, 255), 1.00, "bankgothic", "center", "center", false, false, true, true, false) setTimer ( function() local sWidth, sHeight = guiGetScreenSize() destroyElement(yazi1) yazi2 = dxDrawText("text zone", 0, sHeight-29, sWidth, sHeight, tocolor(255, 255, 255, 255), 1.00, "bankgothic", "center", "center", false, false, true, true, false) end, 10000, 1 ) destroyElement(yazi2) send() end addEventHandler( "zorqrok" , getRootElement(),send)
Karuzo Posted March 29, 2014 Posted March 29, 2014 That doesn't make any sense. I just fixed the event problem.
Castillo Posted March 29, 2014 Posted March 29, 2014 dxDrawText doesn't return an element, it returns a boolean ( true/false ). To "destroy" it, just stop rendering it.
undefined Posted March 29, 2014 Author Posted March 29, 2014 I do not understand. All translations sucks.
undefined Posted March 29, 2014 Author Posted March 29, 2014 Solid, i dont understand. Can you help me, pls?
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now