Jump to content

×| مســاعده |× لم تتم الافاده


Sfa7

Recommended Posts

  • Replies 56
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

والله مادري سويت كذا

وماضبط احس اني مخربط الدنيا

\

GUIEditor_Grid = {} 
  
Vehicle = guiCreateWindow(453,218,302,379,"x[ Vehicle Systm ]x",false) 
guiSetVisible(Vehicle ,false) 
guiSetAlpha(Vehicle,1) 
set = guiCreateButton(0.0795,0.8575,0.4007,0.1135,"x[ set ]x",true,Vehicle) 
close = guiCreateButton(0.5166,0.8602,0.4007,0.1135,"x[ close ]x",true,Vehicle) 
GUIEditor_Grid[1] = guiCreateGridList(0.106,0.1214,0.7583,0.6887,true,Vehicle) 
guiGridListSetSelectionMode(GUIEditor_Grid[1],2) 
  
guiGridListAddColumn(GUIEditor_Grid[1],"Vehicle  ",0.2) 
  
for i = 1, 1 do 
    guiGridListAddRow(GUIEditor_Grid[1]) 
end 
  
guiGridListSetItemText(GUIEditor_Grid[1],0,1,"sultan", false, false) 
  
guiSetAlpha(GUIEditor_Grid[1],0.89999997615814) 
  
  
theMarker = createMarker ( -3568.44434, -3001.70483, 45.00222, "cylinder", 2, 0, 255, 0, 255 ) 
  
  
  
addEventHandler("onClientMarkerHit",theMarker, 
  function (player) 
        if (getElementType (player) == "player") and (player == localPlayer) and not isPedInVehicle (player) then 
            guiSetVisible(Vehicle,true) 
            showCursor(true) 
        end 
    end 
) 
  
  
  
function Buttons() 
      if source == set then 
         triggerServerEvent("set",localPlayer) 
         set = createVehicle ( 429, -3568.44434, -3001.70483, 45.00222 ) 
         warpPedIntoVehicle ( source, set ) 
elseif source == close then 
         guiSetVisible(Vehicle,false) 
         showCursor(false) 
           end 
end 
addEventHandler ( "onClientGUIClick",root,Buttons) 

انت عافس الكلنت بالسيرفر :lol:

Link to comment
والله مادري سويت كذا

وماضبط احس اني مخربط الدنيا

\

GUIEditor_Grid = {} 
  
Vehicle = guiCreateWindow(453,218,302,379,"x[ Vehicle Systm ]x",false) 
guiSetVisible(Vehicle ,false) 
guiSetAlpha(Vehicle,1) 
set = guiCreateButton(0.0795,0.8575,0.4007,0.1135,"x[ set ]x",true,Vehicle) 
close = guiCreateButton(0.5166,0.8602,0.4007,0.1135,"x[ close ]x",true,Vehicle) 
GUIEditor_Grid[1] = guiCreateGridList(0.106,0.1214,0.7583,0.6887,true,Vehicle) 
guiGridListSetSelectionMode(GUIEditor_Grid[1],2) 
  
guiGridListAddColumn(GUIEditor_Grid[1],"Vehicle  ",0.2) 
  
for i = 1, 1 do 
    guiGridListAddRow(GUIEditor_Grid[1]) 
end 
  
guiGridListSetItemText(GUIEditor_Grid[1],0,1,"sultan", false, false) 
  
guiSetAlpha(GUIEditor_Grid[1],0.89999997615814) 
  
  
theMarker = createMarker ( -3568.44434, -3001.70483, 45.00222, "cylinder", 2, 0, 255, 0, 255 ) 
  
  
  
addEventHandler("onClientMarkerHit",theMarker, 
  function (player) 
        if (getElementType (player) == "player") and (player == localPlayer) and not isPedInVehicle (player) then 
            guiSetVisible(Vehicle,true) 
            showCursor(true) 
        end 
    end 
) 
  
  
  
function Buttons() 
      if source == set then 
         triggerServerEvent("set",localPlayer) 
         set = createVehicle ( 429, -3568.44434, -3001.70483, 45.00222 ) 
         warpPedIntoVehicle ( source, set ) 
elseif source == close then 
         guiSetVisible(Vehicle,false) 
         showCursor(false) 
           end 
end 
addEventHandler ( "onClientGUIClick",root,Buttons) 

سطر 40 و 41 مالهم داعي بالكلينت

ولا تنسى تضيفه بالميتا سيرفر server.lua أفتح ملف جديد و حط اسمه

و استخدم الكود

addEvent 
addEventHandler 

و بعدها أنقل الكود الي بالكلينت الي بسطر40 و 41 إلى ملف السيرفر

Link to comment

صح عليك بس سوي ملف سيرفر ثاني وضيف الايفنت

addEvent -- سوية بـ السيرفر بـ اسم الايفنت الي مسوية

addEventHandler -- سوية بـ السيرفر بـ اسم الايفنت الي مسوية

createVehicle < للسيرفر انقلة

warpPedIntoVehicle < للسيرفر انقلة

Link to comment

كلنت

GUIEditor_Grid = {} 
  
Vehicle = guiCreateWindow(453,218,302,379,"x[ Vehicle Systm ]x",false) 
guiSetVisible(Vehicle ,false) 
guiSetAlpha(Vehicle,1) 
set = guiCreateButton(0.0795,0.8575,0.4007,0.1135,"x[ set ]x",true,Vehicle) 
close = guiCreateButton(0.5166,0.8602,0.4007,0.1135,"x[ close ]x",true,Vehicle) 
GUIEditor_Grid[1] = guiCreateGridList(0.106,0.1214,0.7583,0.6887,true,Vehicle) 
guiGridListSetSelectionMode(GUIEditor_Grid[1],2) 
  
guiGridListAddColumn(GUIEditor_Grid[1],"Vehicle  ",0.2) 
  
for i = 1, 1 do 
    guiGridListAddRow(GUIEditor_Grid[1]) 
end 
  
guiGridListSetItemText(GUIEditor_Grid[1],0,1,"sultan", false, false) 
  
guiSetAlpha(GUIEditor_Grid[1],0.89999997615814) 
  
  
theMarker = createMarker ( -3568.44434, -3001.70483, 45.00222, "cylinder", 2, 0, 255, 0, 255 ) 
  
  
  
addEventHandler("onClientMarkerHit",theMarker, 
  function (player) 
        if (getElementType (player) == "player") and (player == localPlayer) and not isPedInVehicle (player) then 
            guiSetVisible(Vehicle,true) 
            showCursor(true) 
        end 
    end 
) 
  
  
  
function Buttons() 
      if source == set then 
  
elseif source == close then 
         guiSetVisible(Vehicle,false) 
         showCursor(false) 
           end 
end 
addEventHandler ( "onClientGUIClick",root,Buttons) 

سيرفر

         set = createVehicle ( 429, -3568.44434, -3001.70483, 45.00222 ) 
         warpPedIntoVehicle ( source, set ) 
         triggerEvent ( "onSpecialEvent", getRootElement(), "set" ) 

الميتا

    "Sfa7" version="2" type="script" /> 
    

ماادري بس انتو لحستو مخي قلتو شيل الـ

set = createVehicle ( 429, -3568.44434, -3001.70483, 45.00222 )

warpPedIntoVehicle ( source, set )

triggerEvent ( "onSpecialEvent", getRootElement(), "set" )

ولما شلتهم مادري وش احط مكانهم ><

Link to comment
والله مادري سويت كذا

وماضبط احس اني مخربط الدنيا

\

GUIEditor_Grid = {} 
  
Vehicle = guiCreateWindow(453,218,302,379,"x[ Vehicle Systm ]x",false) 
guiSetVisible(Vehicle ,false) 
guiSetAlpha(Vehicle,1) 
set = guiCreateButton(0.0795,0.8575,0.4007,0.1135,"x[ set ]x",true,Vehicle) 
close = guiCreateButton(0.5166,0.8602,0.4007,0.1135,"x[ close ]x",true,Vehicle) 
GUIEditor_Grid[1] = guiCreateGridList(0.106,0.1214,0.7583,0.6887,true,Vehicle) 
guiGridListSetSelectionMode(GUIEditor_Grid[1],2) 
  
guiGridListAddColumn(GUIEditor_Grid[1],"Vehicle  ",0.2) 
  
for i = 1, 1 do 
    guiGridListAddRow(GUIEditor_Grid[1]) 
end 
  
guiGridListSetItemText(GUIEditor_Grid[1],0,1,"sultan", false, false) 
  
guiSetAlpha(GUIEditor_Grid[1],0.89999997615814) 
  
  
theMarker = createMarker ( -3568.44434, -3001.70483, 45.00222, "cylinder", 2, 0, 255, 0, 255 ) 
  
  
  
addEventHandler("onClientMarkerHit",theMarker, 
  function (player) 
        if (getElementType (player) == "player") and (player == localPlayer) and not isPedInVehicle (player) then 
            guiSetVisible(Vehicle,true) 
            showCursor(true) 
        end 
    end 
) 
  
  
  
function Buttons() 
      if source == set then 
         triggerServerEvent("set",localPlayer) 
         set = createVehicle ( 429, -3568.44434, -3001.70483, 45.00222 ) 
         warpPedIntoVehicle ( source, set ) 
elseif source == close then 
         guiSetVisible(Vehicle,false) 
         showCursor(false) 
           end 
end 
addEventHandler ( "onClientGUIClick",root,Buttons) 

سطر 40 و 41 مالهم داعي بالكلينت

ولا تنسى تضيفه بالميتا سيرفر server.lua أفتح ملف جديد و حط اسمه

و استخدم الكود

addEvent 
addEventHandler 

و بعدها أنقل الكود الي بالكلينت الي بسطر40 و 41 إلى ملف السيرفر

وليه حاذف الترقر

Link to comment

عاد جا جعفر مسوي فاهم لو انت مسويها بتطرح موضوع لنها فيها اخطا

المهم انا اقولك ماصارلي سبوع اتعلم برمجة النوافذ !

طيب اشرحولنا وين نحطها وكذا

مو تعطونا الكود وتقول روح سو ؟

Link to comment
عاد جا جعفر مسوي فاهم لو انت مسويها بتطرح موضوع لنها فيها اخطا

المهم انا اقولك ماصارلي سبوع اتعلم برمجة النوافذ !

طيب اشرحولنا وين نحطها وكذا

مو تعطونا الكود وتقول روح سو ؟

هههه انا مسوي اقتباس لكلام تابل مهب كلامي

Link to comment

أرجع أقرأ ردي مره ثانية

أنا قلت لك أستخدم الكودين في ملف السيرفر

addEvent 
addEventHandler 

بس ما أشوفك أستخدمتهم

و ذا الكود ليه حذفته من الكلينت؟

triggerServerEvent("set",localPlayer) 

و هذا السطر ليه حاطه؟

احذفه ماله داعي

triggerEvent ( "onSpecialEvent", getRootElement(), "set" ) 

Link to comment

كلنت

GUIEditor_Grid = {} 
  
Vehicle = guiCreateWindow(453,218,302,379,"x[ Vehicle Systm ]x",false) 
guiSetVisible(Vehicle ,false) 
guiSetAlpha(Vehicle,1) 
set = guiCreateButton(0.0795,0.8575,0.4007,0.1135,"x[ set ]x",true,Vehicle) 
close = guiCreateButton(0.5166,0.8602,0.4007,0.1135,"x[ close ]x",true,Vehicle) 
GUIEditor_Grid[1] = guiCreateGridList(0.106,0.1214,0.7583,0.6887,true,Vehicle) 
guiGridListSetSelectionMode(GUIEditor_Grid[1],2) 
  
guiGridListAddColumn(GUIEditor_Grid[1],"Vehicle  ",0.2) 
  
for i = 1, 1 do 
    guiGridListAddRow(GUIEditor_Grid[1]) 
end 
  
guiGridListSetItemText(GUIEditor_Grid[1],0,1,"sultan", false, false) 
  
guiSetAlpha(GUIEditor_Grid[1],0.89999997615814) 
  
  
theMarker = createMarker ( -3568.44434, -3001.70483, 45.00222, "cylinder", 2, 0, 255, 0, 255 ) 
  
  
  
addEventHandler("onClientMarkerHit",theMarker, 
  function (player) 
        if (getElementType (player) == "player") and (player == localPlayer) and not isPedInVehicle (player) then 
            guiSetVisible(Vehicle,true) 
            showCursor(true) 
        end 
    end 
) 
  
  
  
function Buttons() 
      if source == set then 
         triggerServerEvent("set",localPlayer) 
  
elseif source == close then 
         guiSetVisible(Vehicle,false) 
         showCursor(false) 
           end 
end 
addEventHandler ( "onClientGUIClick",root,Buttons) 

سيرفر

         set = createVehicle ( 429, -3568.44434, -3001.70483, 45.00222 ) 
         warpPedIntoVehicle ( source, set ) 
         triggerServerEvent("set",localPlayer) 
         addEventHandler( "onPlayerSpawn", Buttons, set ) 

احس كله غلط

Link to comment

ككذا ؟

         triggerServerEvent("set",localPlayer) 
         addEventHandler( "onPlayerSpawn", localPlayer, set ) 
         set = createVehicle ( 429, -3568.44434, -3001.70483, 45.00222 ) 
         warpPedIntoVehicle ( source, set ) 

Link to comment
ككذا ؟
         triggerServerEvent("set",localPlayer) 
         addEventHandler( "onPlayerSpawn", localPlayer, set ) 
         set = createVehicle ( 429, -3568.44434, -3001.70483, 45.00222 ) 
         warpPedIntoVehicle ( source, set ) 

كيف تحط تريقر السيرفر في السيرفر ؟؟

تريقر السيرفر يكون في الكلنت

وتريقر الكلنت يكون في السيرفر

+

أي فنكشن لونه أحمر يعني كلنت بس زي

triggerServerEvent 

وأي فنكشن لونه برتقالي يكون سيرفر بس زي

triggerClientEvent 

Link to comment

+

localPlayer كلينت فقط

السيرفر يكون كذا

addEvent("set", true) 
addEventHandler("set", root, 
function() 
     sett = createVehicle ( 429, -3568.44434, -3001.70483, 45.00222 ) 
     warpPedIntoVehicle ( source, sett ) 
end) 

Link to comment

سيررفر

         addEventHandler( "onPlayerSpawn", localPlayer, set ) 
         set = createVehicle ( 429, -3568.44434, -3001.70483, 45.00222 ) 
         warpPedIntoVehicle ( source, set ) 

كلنت

GUIEditor_Grid = {} 
  
Vehicle = guiCreateWindow(453,218,302,379,"x[ Vehicle Systm ]x",false) 
guiSetVisible(Vehicle ,false) 
guiSetAlpha(Vehicle,1) 
set = guiCreateButton(0.0795,0.8575,0.4007,0.1135,"x[ set ]x",true,Vehicle) 
close = guiCreateButton(0.5166,0.8602,0.4007,0.1135,"x[ close ]x",true,Vehicle) 
GUIEditor_Grid[1] = guiCreateGridList(0.106,0.1214,0.7583,0.6887,true,Vehicle) 
guiGridListSetSelectionMode(GUIEditor_Grid[1],2) 
  
guiGridListAddColumn(GUIEditor_Grid[1],"Vehicle  ",0.2) 
  
for i = 1, 1 do 
    guiGridListAddRow(GUIEditor_Grid[1]) 
end 
  
guiGridListSetItemText(GUIEditor_Grid[1],0,1,"sultan", false, false) 
  
guiSetAlpha(GUIEditor_Grid[1],0.89999997615814) 
  
  
theMarker = createMarker ( -3568.44434, -3001.70483, 45.00222, "cylinder", 2, 0, 255, 0, 255 ) 
  
  
  
addEventHandler("onClientMarkerHit",theMarker, 
  function (player) 
        if (getElementType (player) == "player") and (player == localPlayer) and not isPedInVehicle (player) then 
            guiSetVisible(Vehicle,true) 
            showCursor(true) 
        end 
    end 
) 
  
  
  
function Buttons() 
      if source == set then 
         triggerServerEvent("set",localPlayer) 
          
elseif source == close then 
         guiSetVisible(Vehicle,false) 
         showCursor(false) 
           end 
end 
addEventHandler ( "onClientGUIClick",root,Buttons) 

صح ولا غلط ؟

Link to comment

الحين خلصت كل شي

بس الكلنت الحين فيه شي .؟

GUIEditor_Grid = {} 
  
Vehicle = guiCreateWindow(453,218,302,379,"x[ Vehicle Systm ]x",false) 
guiSetVisible(Vehicle ,false) 
guiSetAlpha(Vehicle,1) 
set = guiCreateButton(0.0795,0.8575,0.4007,0.1135,"x[ set ]x",true,Vehicle) 
close = guiCreateButton(0.5166,0.8602,0.4007,0.1135,"x[ close ]x",true,Vehicle) 
GUIEditor_Grid[1] = guiCreateGridList(0.106,0.1214,0.7583,0.6887,true,Vehicle) 
guiGridListSetSelectionMode(GUIEditor_Grid[1],2) 
  
guiGridListAddColumn(GUIEditor_Grid[1],"Vehicle  ",0.2) 
  
for i = 1, 1 do 
    guiGridListAddRow(GUIEditor_Grid[1]) 
end 
  
guiGridListSetItemText(GUIEditor_Grid[1],0,1,"sultan", false, false) 
  
guiSetAlpha(GUIEditor_Grid[1],0.89999997615814) 
  
  
theMarker = createMarker ( -3568.44434, -3001.70483, 45.00222, "cylinder", 2, 0, 255, 0, 255 ) 
  
  
  
addEventHandler("onClientMarkerHit",theMarker, 
  function (player) 
        if (getElementType (player) == "player") and (player == localPlayer) and not isPedInVehicle (player) then 
            guiSetVisible(Vehicle,true) 
            showCursor(true) 
        end 
    end 
) 
  
  
  
function Buttons() 
      if source == set then 
         triggerServerEvent("set",localPlayer) 
          
elseif source == close then 
         guiSetVisible(Vehicle,false) 
         showCursor(false) 
           end 
end 
addEventHandler ( "onClientGUIClick",root,Buttons) 

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...