-
Posts
10,056 -
Joined
-
Last visited
-
Days Won
27
Everything posted by iPrestege
-
Where's this command ?
-
What you mean by auto load like a spawn or something like that ?
-
I Don't think that but try this : setPedAnimation ( ped1, "BAR", "Barcustom_loop",false,true,true,true )
-
-- # Server Side addCommandHandler ( "pescar", function ( player ) local vehicle = getPedOccupiedVehicle ( player ) if not vehicle then return end if ( getElementModel ( vehicle ) == 493 ) then givePlayerMoney ( player, 500 ) outputChatBox ( "#FFFF00Você pescou um Peixe e ganhou R$500",player, 255, 255, 255, true ) else outputChatBox ( "#B03060Você precisa estar dentro de um Barco para usar este comando ( /pescar )",player, 255, 255, 255, true ) end end )
-
Do you mean you want to add the command handler 'pescar' just if you are on 493 boat ?
-
-- # Server Side function marinha (thePlayer) if ( getElementModel ( source ) == 493 ) then outputChatBox ( "#B03060Você precisa estar dentro de um Barco para usar este comando ( /pescar )",thePlayer, 255, 255, 255, true ) cancelEvent( true ) end end addEventHandler ( "onVehicleStartEnter", getRootElement(), marinha ) function gdinheiro (thePlayer) getPlayerMoney(thePlayer) givePlayerMoney ( thePlayer, 500 ) outputChatBox ( "#FFFF00Você pescou um Peixe e ganhou R$500",thePlayer, 255, 255, 255, true ) end addCommandHandler ( "pescar", gdinheiro ) Does that what are you trying to do?
-
يواصل حملته التي انطلقت أمس وتستمر خلال الأيام القادمة في أحياء عدة بالصور.. مرور شرق الرياض يحجز 8 سيارات ويحرر 190 مخالفة عبدالله البرقاوي- سبق- الرياض: يواصل مرور منطقة الرياض تنفيذ حملة مرورية واسعة على أحياء شرق الرياض، وهي الحملة التي انطلقت أمس، ولا تزال متواصلة وستستمر خلال الأيام القادمة, حيث تم حجز 8 سيارات وتحرير 190 مخالفة في 24 ساعة. وقال رئيس مركز القيادة والتحكم الناطق الرسمي بمرور الرياض المقدم حسن الحسن لـ "سبق": إن الحملة شملت عدة أحياء في شرق الرياض، منها النسيم والنظيم والجنادرية والخليج، مشيراً إلى استمرار الحملة لكثرة البلاغات من هذه المنطقة. وبين الحسن أن الحملة عامة لجميع المخالفات، فيما جاء في إحصائياتها أمس تحرير 199 مخالفه وحجز 8 سيارات، بينها سيارة ضبطت خلال ممارسة سائقها التفحيط. وقال الحسن إن الحملة تضمنت منع دخول الشاحنات في الأوقات غير المسموح بها، فيما تنوعت المخالفات التي جرى ضبطها بين عدم ربط حزام الأمان، واستخدام الجوال، والتظليل، وعدم وجود رخصة، وغيرها من المخالفات بما فيها التفحيط. وأوضح الحسن أن حجز المركبات جاء لمخالفات التفحيط وعدم وجود رخصة وغيرها من المخالفات، مؤكداً استمرار الحملة حرصاً على سلامة الجميع.
-
Try to make a event for each button that's would be better . -- # Client Side addEventHandler("onClientGUIClick",buttonDefault, function ( ) guiGridListClear (wstyleG) for i,Default in ipairs(Default) do local row = guiGridListAddRow(wstyleG) guiGridListSetItemText(wstyleG, row, 1, tostring(Default[1]), false, false) guiGridListSetItemData(wstyleG, row, 1, tostring(Default[2])) guiSetEnabled ( buttonDefault, false ) guiSetEnabled ( buttonMan, true ) guiSetEnabled ( buttonWoman, true ) guiSetEnabled ( buttonOther, true ) end end,false ) addEventHandler("onClientGUIClick",buttonMan, function ( ) guiGridListClear (wstyleG) for i,Woman in ipairs(Woman) do local row = guiGridListAddRow(wstyleG) guiGridListSetItemText(wstyleG, row, 1, tostring(Woman[1]), false, false) guiGridListSetItemData(wstyleG, row, 1, tostring(Woman[2])) guiSetEnabled ( buttonDefault, true ) guiSetEnabled ( buttonMan, true ) guiSetEnabled ( buttonWoman, false ) guiSetEnabled ( buttonOther, true ) end end,false ) addEventHandler("onClientGUIClick",buttonWoman, function ( ) guiGridListClear (wstyleG) for i,Woman in ipairs(Woman) do local row = guiGridListAddRow(wstyleG) guiGridListSetItemText(wstyleG, row, 1, tostring(Woman[1]), false, false) guiGridListSetItemData(wstyleG, row, 1, tostring(Woman[2])) guiSetEnabled ( buttonDefault, true ) guiSetEnabled ( buttonMan, true ) guiSetEnabled ( buttonWoman, false ) guiSetEnabled ( buttonOther, true ) end end,false ) addEventHandler("onClientGUIClick",buttonOther, function ( ) guiGridListClear (wstyleG) for i,Other in ipairs(Other) do local row = guiGridListAddRow(wstyleG) guiGridListSetItemText(wstyleG, row, 1, tostring(Other[1]), false, false) guiGridListSetItemData(wstyleG, row, 1, tostring(Other[2])) guiSetEnabled ( buttonDefault, true ) guiSetEnabled ( buttonMan, true ) guiSetEnabled ( buttonWoman, true ) guiSetEnabled ( buttonOther, false ) end end,false )
-
-- # Client Side function list() if (source == buttonDefault) then guiGridListClear (wstyleG) for i,Default in ipairs(Default) do local row = guiGridListAddRow(wstyleG) guiGridListSetItemText(wstyleG, row, 1, tostring(Default[1]), false, false) guiGridListSetItemData(wstyleG, row, 1, tostring(Default[2])) guiSetEnabled ( buttonDefault, false ) guiSetEnabled ( buttonMan, true ) guiSetEnabled ( buttonWoman, true ) guiSetEnabled ( buttonOther, true ) end elseif (source == buttonMan) then guiGridListClear (wstyleG) for i,Man in ipairs(Man) do local row = guiGridListAddRow(wstyleG) guiGridListSetItemText(wstyleG, row, 1, tostring(Man[1]), false, false) guiGridListSetItemData(wstyleG, row, 1, tostring(Man[2])) guiSetEnabled ( buttonDefault, true ) guiSetEnabled ( buttonMan, false ) guiSetEnabled ( buttonWoman, true ) guiSetEnabled ( buttonOther, true ) end elseif (source == buttonWoman) then guiGridListClear (wstyleG) for i,Woman in ipairs(Woman) do local row = guiGridListAddRow(wstyleG) guiGridListSetItemText(wstyleG, row, 1, tostring(Woman[1]), false, false) guiGridListSetItemData(wstyleG, row, 1, tostring(Woman[2])) guiSetEnabled ( buttonDefault, true ) guiSetEnabled ( buttonMan, true ) guiSetEnabled ( buttonWoman, false ) guiSetEnabled ( buttonOther, true ) end elseif (source == buttonOther) then guiGridListClear (wstyleG) for i,Other in ipairs(Other) do local row = guiGridListAddRow(wstyleG) guiGridListSetItemText(wstyleG, row, 1, tostring(Other[1]), false, false) guiGridListSetItemData(wstyleG, row, 1, tostring(Other[2])) guiSetEnabled ( buttonDefault, true ) guiSetEnabled ( buttonMan, true ) guiSetEnabled ( buttonWoman, true ) guiSetEnabled ( buttonOther, false ) end end end
-
-- # Server Side object = { } addEvent("CreateTheObject",true) addEventHandler("CreateTheObject",getRootElement(), function ( Model ) if ( object[source] and isElement ( object[source] ) ) then destroyElement ( object[source] ) end local x,y,z = getElementPosition ( source ) object[source] = createObject ( Model , x , y , z ) setAccountData ( getPlayerAccount ( source ) , "Model" , getElementModel ( object[source] ) ) exports.bone_attach:attachElementToBone(object[source],source,1,0,0,0.1,0,0,0) if getElementModel ( object[source] ) == 3515 then setObjectScale ( object[source] , 0.2 ) end if getElementModel ( object[source] ) == 1248 then setObjectScale ( object[source] , 1.3 ) exports.bone_attach:attachElementToBone(object[source],source,1,0,0.03,0.1,0,0,180) end if getElementModel ( object[source] ) == 2045 then setObjectScale ( object[source] , 1 ) exports.bone_attach:attachElementToBone(object[source],source,12,-0.2,0,0.08,0,0,90) end if getElementModel ( object[source] ) == 13562 then setObjectScale ( object[source] , 0.2 ) exports.bone_attach:attachElementToBone(object[source],source,1,0,0.03,0.2,0,0,0) end if getElementModel ( object[source] ) == 1512 then setObjectScale ( object[source] , 0.1 ) setElementAlpha ( object[source] , 0 ) exports.bone_attach:attachElementToBone(object[source],source,1,0,0.03,0.1,0,0,180) end if getElementModel ( object[source] ) == 3524 then setObjectScale ( object[source] , 0.4 ) exports.bone_attach:attachElementToBone(object[source],source,1,0,0.036,-0.8,0,0,180) end if getElementModel ( object[source] ) == 2908 then setObjectScale ( object[source] , 1.4 ) exports.bone_attach:attachElementToBone(object[source],source,1,0,0.1,0.1,270,90,0) end if getElementModel ( object[source] ) == 1485 then setObjectScale ( object[source] , 1.4 ) exports.bone_attach:attachElementToBone(object[source],source,1, -0.01, -0.01, -0.035, 0, 90, 0 ) end if getElementModel ( object[source] ) == 330 then setObjectScale ( object[source] , 1 ) exports.bone_attach:attachElementToBone(object[source],source,12, 0, 0, 0.01, 0, -50, 0 ) end if getElementModel ( object[source] ) == 3027 then setObjectScale ( object[source] , 1.3 ) exports.bone_attach:attachElementToBone(object[source],source,1, -0.01, 0.09, 0, 90, 90, 90 ) smoke = createObject ( 1485 , x , y , z ) exports.bone_attach:attachElementToBone(smoke,source,1, -0.02, 0.06, 0.03, 90, 90, 0 ) setElementAlpha ( smoke , 0 ) end if getElementModel ( object[source] ) == 1485 then setObjectScale ( object[source] , 1.4 ) exports.bone_attach:attachElementToBone(object[source],source,1, -0.01, -0.01, -0.035, 90, 0, 0 ) end if getElementModel ( object[source] ) == 1736 then setElementDoubleSided ( object[source], true ) exports.bone_attach:attachElementToBone(object[source],source,1, 0, 0, 0, 0, 0, 180 ) end if getElementModel ( object[source] ) == 2589 then setElementDoubleSided ( object[source], true ) exports.bone_attach:attachElementToBone(object[source],source,1, 0, 0, -0.9, 0, 180, 180 ) end if getElementModel ( object[source] ) == 1786 then setElementDoubleSided ( object[source], true ) exports.bone_attach:attachElementToBone(object[source],source,1, 0, -0.15, -0.2, 0, 0, 180 ) end if getElementModel ( object[source] ) == 16779 then setElementDoubleSided ( object[source], true ) exports.bone_attach:attachElementToBone(object[source],source,1, 0, 0, -0.1, 0, 180, 180 ) end if getElementModel ( object[source] ) == 3528 then setObjectScale ( object[source] , 0.09 ) setElementDoubleSided ( object[source], true ) exports.bone_attach:attachElementToBone(object[source],source,1, 0.018, 0.1, 0.1, 0, 0, 90 ) end if getElementModel ( object[source] ) == 7093 then setObjectScale ( object[source] , 0.2 ) setElementDoubleSided ( object[source], true ) setElementCollisionsEnabled ( object[source], true ) exports.bone_attach:attachElementToBone(object[source],source,1, 0, 0.6, 0.2, 0, 0, 0 ) end end ) addEventHandler("onPlayerQuit",getRootElement(), function ( ) if ( object[source] and isElement ( object[source] ) ) then destroyElement ( object[source] ) object[source] = nil end end ) addEventHandler ( "onPlayerLogin", root, function ( _,account ) local ObjectID = getAccountData ( account,"Model" ) if ( object[source] and isElement ( object[source] ) ) then destroyElement ( object[source] ) object[source] = nil end local x,y,z = getElementPosition ( source ) object[ source ] = createObject ( ObjectID , x,y,z ) if ( object[source] and isElement ( object[source] ) ) then exports.bone_attach:attachElementToBone(object[source],source,1,0,0,0.1,0,0,0) end if getElementModel ( object[source] ) == 2045 then setObjectScale ( object[source] , 1 ) exports.bone_attach:attachElementToBone(object[source],source,12,-0.2,0,0.08,0,0,90) end end )
-
You can destroy the object : Event : "onPlayerQuit" isElement destroyElement
-
Make it like that : if getElementModel ( object[source] ) == 3528 then setObjectScale ( object[source] , 0.09 ) setElementDoubleSided ( object[source], true )
-
والله مدري وحياكـ الله .. ذذ
-
اي استخدم اللي عطيتك
-
Event : "onPlayerJoin" spawnPlayer
-
I Don't see any function with 'targetPlayer' Handler function ?
-
Yes, I've reported the topic and I think the mta moderators will soon move the topic to the right section . -- # Server Side function pedLoad () ped1 = createPed( 247, 2242.598, 2151.254, 10.67,115 ) setTimer( function ( ) setPedAnimation ( ped1, "BAR", "Barcustom_loop", 1, true, true, true ) giveWeapon ( ped1,34,1,true ) end,50,1 ) end addEventHandler ( "onResourceStart",resourceRoot, pedLoad )
-
حياكـ الله .. و يوم تغير عنوان الموضوع خلة نفسة لانة فية ناس تحتاج ذذ اكتب تم جنب العنوان الاصلي آفضل
-
You're welcome and you're code doesn't have a much sense try 'Robbster' One .
-
You can't use this command you will get a mta error.
-
يمكنك نسختة خطأ ؟ انسخهم ثانية / = ؟
-
You're script doesn't make a sense until now but there's a problem you are using a 'bind' Command but the command is already handled on the mta -.- you can't use it.