Jump to content

Mr.Mostafa

Members
  • Posts

    1,377
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by Mr.Mostafa

  1. سلام عليكم ورحمة الله وبركاته . في احد يعرف يبرمج في هذا البرنامج .. Visual basic 2010 Express؟
  2. دامك مبتدئ بالبرمجة .. شوف مودات مستر جراند حقت الاملاك الخاصة -- لها نفس الفكرة الي تقول عليها تعلم من اكوادها ,, موداته مب مشفرة ..
  3. تمام بس وش وظيفته هادا , او كيف استخدمه ؟
  4. سلام عليكم عندي مشكلة بقاعدة بيانات انا ابي لو كتبت /nt وكلمة الكلمة يكون لها ايدي مخفي في قاعدة البيانات .. والايدي يكون الايدي الي عليه الدور ولو كتبت /st واي ايدي يجبلي الكلمة الي محفوظة في الايدي هادا executeSQLQuery( "CREATE TABLE IF NOT EXISTS testss ( id,text )" ) addCommandHandler("nt", function ( source,cmd,text ) if text then outputChatBox("* "..text.."",source,0,255,0,true) local checkSQL = executeSQLQuery ( "SELECT * FROM testss") local new = checkSQL.id or 0 local insert = executeSQLQuery( "INSERT INTO testss ( id, text ) VALUES( ? , ? )", new+1, text ) if insert then outputChatBox("done",source,255,0,0,true) end else outputChatBox("* insert text",source,255,0,0,true) end end ) addCommandHandler("st", function ( source,cmd,id ) if id then local Query = executeSQLQuery("SELECT * FROM testss WHERE id", id) outputChatBox("* result : "..Query.text.."",source,0,255,0,true) outputChatBox("* id : "..id.."",source,0,255,0,true) else outputChatBox("* insert text",source,255,0,0,true) end end )
  5. سلام عليكم ممكن تصحيح لهذا الكود local buttons = { ['GUIEditor.button[1]'] = {message = 'this is button 1'}, ['GUIEditor.button[2]'] = {message = 'this is button 2'}, } addEventHandler("onClientGUIClick", root, function () if buttons[source] then outputChatBox(buttons[source].message,255,0,0,true) end end )
  6. هادا التحقق يشوف موجود صوت متركب ولا لا انا ابي اعرف رابط الصوت الي حطيته شغال او لا
  7. ما ظبطت addCommandHandler("cs", function () if sound == false then outputChatBox("لا يوجد صوت",255,0,0,true) else outputChatBox("يوجد صوت",255,0,0,true) end end )
  8. سلام عليكم مافي طريقة اتحقق ان الرابط شغال او لالا يعني ابي لو الرابط مرفوع عليه صوت تشتغل , غير كذا لا .. addEventHandler("onClientGUIClick",root, function () if source == GUIEditor.button[1] then local link = guiGetText(GUIEditor.edit[1]) sound = playSound3D(link, 1,2,3, true) setSoundMaxDistance(sound, 25) setSoundVolume(sound, 20.0) end end )
  9. لازم خادم لحاله , عشان تربط عليه بوت الدسكورد يكون شغال علطول
  10. اي تمام كنت صاير ادور علي الايفنت , بس ما انتبهت للاكواد زين ..
  11. بدل الكود بدا addEvent( 'saveNameAndData' , true ) addEventHandler( 'saveNameAndData' , root , function( text ) local data = executeSQLQuery( 'select * from _aSoking' ) if ( #data == 0 or not data ) then executeSQLQuery( 'insert into _aSoking( Name , Text ) values( ? , ? ) ' , toJSON( { getPlayerName( source ) } ) , toJSON( { text } ) ) local Names2 , Text2 = fromJSON( data[ 1 ][ 'Name' ] ) , fromJSON( data[ 1 ][ 'Text' ] ) triggerClientEvent( root , 'clearGridList' , resourceRoot ) for i = 1 , #Names2 do triggerClientEvent( root , 'setDataOnGridlist' , resourceRoot , Names2[ i ] , Text2[ i ] ) end else local Names , Text = fromJSON( data[ 1 ][ 'Name' ] ) , fromJSON( data[ 1 ][ 'Text' ] ) table.insert( Names , getPlayerName( source ) ) ; table.insert( Text , text ) executeSQLQuery( 'update _aSoking set Name = ? , Text = ?' , toJSON( Names ) , toJSON( Text ) ) end
  12. بتحصل شي بالمود كدا تقريبا If msg == "ديربي" then بعد السطر دا حط الكود .. ولو ما ظبطت .. اطرح اكواد السيرفر عشان نشوف وش الالمنت بمودك
  13. سلام عليكم ؟ outputChatBox في طريقة اقدر اعدل علي فنكشن
  14. getPlayerName(localPlayer or source) -- local player = client -- source = server لو ما عرفت تسويها , اطرح الاكواد كاملة + انت مسوي تحقق بقاعدة اسمها بنك , ومب حاطط بالمود انشاء قاعدة اسمها بنك تقريبا تبي تسوي كذا والله اعلم -- Client addEventHandler('onClientResourceStart' , resourceRoot , function ( ) triggerServerEvent ( 'EventS' , localPlayer ) guiSetFont( gridNews , "default-bold-small") end ) addEvent('EventT2' , true ) addEventHandler('EventT2' , getRootElement ( ), function ( Value ) guiGridListClear( gridNews ) for Value1 , Value2 in ipairs ( Value ) do local aRowz = guiGridListAddRow ( gridNews ) guiGridListSetItemText ( gridNews , aRowz , 1 , Value2.aRows , false , false ) guiGridListSetItemText ( gridNews , aRowz , 2 , Value2.playerName , false , false ) guiGridListSetItemColor ( gridNews , aRowz , 1 , math.random ( 255 ), math.random ( 255 ), math.random ( 255 ) ) end end ) -- Server executeSQLQuery ( 'CREATE TABLE IF NOT EXISTS aSoking ( aRows,playerName )' ) addEvent('Event', true ) addEventHandler('Event' , getRootElement ( ) , function ( aText ) executeSQLQuery('INSERT INTO aSoking (aRows, playerName) VALUES(?, ?)', aText, getPlayerName(source)) outputChatBox('You Have Add '..aText..'', source , 255,0,0) triggerEvent("EventS",source) end ) addEvent('EventS', true ) addEventHandler('EventS' , getRootElement ( ) , function ( ) Value = executeSQLQuery( 'SELECT * FROM aSoking' ) if ( #Value ~= 0 ) then triggerClientEvent ( source , 'EventT2' , source , Value ) end end )
  15. الكود حقك ما يجيب لون الاسم الخاص بنكك , لكن لو تبي تغير لون اسمك بيكون كدا setPlayerNametagColor
  16. يب بس يمكن كود تغير اللون خربان , فا ما يغير , فا بتضل نفس النتيجة , فهمتني؟
  17. الكود حقك صحيح , لكن تاكد من كود تغير اللون
  18. تمام .. لما افتح ان شاء الله اسويها .. بس كنت مفكر ان تيبل ريموف ماله ارقمنتات ويحذف اول شي في الجدول
×
×
  • Create New...