ABO-SR777777A Posted July 7, 2013 Author Share Posted July 7, 2013 bindKey ( "F2" , "down" , function() if ( guiGetVisible ( GUIEditor_Window[1] ) == true ) then guiSetVisible ( GUIEditor_Window[1] ,false ) showCursor (false ) guiSetInputEnabled(false) elseif ( guiGetVisible ( GUIEditor_Window[1] ) == false ) then guiSetVisible ( GUIEditor_Window[1] ,true ) showCursor (false ) guiSetInputEnabled(true) end end ) ناقله Link to comment
ABO-SR777777A Posted July 7, 2013 Author Share Posted July 7, 2013 addEvent("register",true) addEventHandler("register",root, function(player,userName,Password) if ( password ~= "" and password ~= nil ) then local accountAdded = addAccount( getPlayerName(source), password ) if ( accountAdded ) then outputChatBox ( "Thank you " .. getPlayerName(source) .. ", you're now registed, you can login with /login", source ) else outputChatBox ( "Error creating account, contact the server admin", source ) end else outputChatBox ( "Error creating account, correct syntax: /register ", source ) end end addCommandHandler ( "register", registerPlayer ) Link to comment
#Al-Ha[J]aRii Posted July 7, 2013 Share Posted July 7, 2013 bindKey ( "F2" , "down" , function() if ( guiGetVisible ( GUIEditor_Window[1] ) == true ) then guiSetVisible ( GUIEditor_Window[1] ,false ) showCursor (false ) guiSetInputEnabled(false) elseif ( guiGetVisible ( GUIEditor_Window[1] ) == false ) then guiSetVisible ( GUIEditor_Window[1] ,true ) showCursor (false ) guiSetInputEnabled(true) end end ) ناقله كيف لين تظهر النافدة تخليه مايطلع الماوس استبدل سطر 8 بـــــــــــــــــــــــــــــ showCursor (true) Link to comment
iPrestege Posted July 7, 2013 Share Posted July 7, 2013 bindKey ( 'F2','down', function ( ) local v = guiGetVisible ( GUIEditor_Window[1] ) guiSetVisible ( GUIEditor_Window[1],not v ) showCursor ( v ) end ) Link to comment
فاّرس Posted July 7, 2013 Share Posted July 7, 2013 (edited) bindKey ( "F2" , "down" , function() if ( guiGetVisible ( GUIEditor_Window[1] ) == true ) then guiSetVisible ( GUIEditor_Window[1] ,false ) showCursor (false ) guiSetInputEnabled(false) elseif ( guiGetVisible ( GUIEditor_Window[1] ) == false ) then guiSetVisible ( GUIEditor_Window[1] ,true ) showCursor (false ) guiSetInputEnabled(true) end end ) ناقله اختصر كذا ذذ bindKey("F2","down", function() guiSetVisible(Window,not guiGetVisible(Window)) showCursor(guiGetVisible(Windiw)) guiSetEnabled(guiGetVisible(Window)) end ) + اذا بتاخذ اكواد جاهزه ما بتتعلم ذذ Edited July 7, 2013 by Guest Link to comment
ABO-SR777777A Posted July 7, 2013 Author Share Posted July 7, 2013 ابيه بس لي login addEventHandler ("onClientGUIClick", root, function() if ( source == login ) then triggerServerEvent("login",getLocalPlayer(), guiGetText(user), guiGetText(pass)) end ) Link to comment
iPrestege Posted July 7, 2013 Share Posted July 7, 2013 (edited) bindKey ( "F2" , "down" , function() if ( guiGetVisible ( GUIEditor_Window[1] ) == true ) then guiSetVisible ( GUIEditor_Window[1] ,false ) showCursor (false ) guiSetInputEnabled(false) elseif ( guiGetVisible ( GUIEditor_Window[1] ) == false ) then guiSetVisible ( GUIEditor_Window[1] ,true ) showCursor (false ) guiSetInputEnabled(true) end end ) ناقله اختصر كذا ذذ bindKey("F2","down", function() guiSetVisible(Window,not guiGetVisible(Window)) showCursor(guiGetVisible(Windiw)) guiSetEnabled(guiGetVisible(Window),false) end ) + اذا بتاخذ اكواد جاهزه ما بتتعلم ذذ guiSetEnabled(guiGetVisible(Window),false) Edited July 7, 2013 by Guest Link to comment
فاّرس Posted July 7, 2013 Share Posted July 7, 2013 حطيته اول كذا , guiSetEnabled(guiGetVisible(Window)) لكن شفت الويكي ناقص ارقومنت ذذ Link to comment
iPrestege Posted July 7, 2013 Share Posted July 7, 2013 حطيته اول كذا ,guiSetEnabled(guiGetVisible(Window)) لكن شفت الويكي ناقص ارقومنت ذذ guiGetVisible(Window) guiElement Link to comment
ABO-SR777777A Posted July 7, 2013 Author Share Posted July 7, 2013 حطيته كله كلينت ماشتغل addEvent("Login",true) addEventHandler("Login",root, function( userName,Password ) local v = getAccount ( username, Password ) if ( v ~= false ) then logIn ( client, v, Password ) else outputChatBox ( "Wrong username or password!", client, 255, 255, 0 ) end end ) addEventHandler ("onClientGUIClick", root, function() if ( source == GUIEditor_Button[2] ) then triggerServerEvent("login",getLocalPlayer(), guiGetText(user), guiGetText(pass)) end end ) Link to comment
iPrestege Posted July 7, 2013 Share Posted July 7, 2013 Client : addEventHandler ("onClientGUIClick", root, function() if ( source == GUIEditor_Button[2] ) then triggerServerEvent("login",getLocalPlayer(), guiGetText(user), guiGetText(pass)) end end ) Server : addEvent("Login",true) addEventHandler("Login",root, function( userName,Password ) local v = getAccount ( username, Password ) if ( v ~= false ) then logIn ( client, v, Password ) else outputChatBox ( "Wrong username or password!", client, 255, 255, 0 ) end end ) Link to comment
ABO-SR777777A Posted July 7, 2013 Author Share Posted July 7, 2013 [15:14:00] ERROR: Client (ROx) triggered serverside event login, but event is not added serverside Link to comment
#Al-Ha[J]aRii Posted July 7, 2013 Share Posted July 7, 2013 (edited) حطيته كله كلينت ماشتغل addEvent("Login",true) addEventHandler("Login",root, function( userName,Password ) local v = getAccount ( username, Password ) if ( v ~= false ) then logIn ( client, v, Password ) else outputChatBox ( "Wrong username or password!", client, 255, 255, 0 ) end end ) addEventHandler ("onClientGUIClick", root, function() if ( source == GUIEditor_Button[2] ) then triggerServerEvent("login",getLocalPlayer(), guiGetText(user), guiGetText(pass)) end end ) [15:14:00] ERROR: Client (ROx) triggered serverside event login, but event is not added serverside يقول لك انت مسوي ترايقر و الترايقر مو محطوط في جهة السيرفر Edited July 7, 2013 by Guest Link to comment
iPrestege Posted July 7, 2013 Share Posted July 7, 2013 [15:14:00] ERROR: Client (ROx) triggered serverside event login, but event is not added serverside حط الكلنت الـ l > L Link to comment
#Al-Ha[J]aRii Posted July 7, 2013 Share Posted July 7, 2013 كيف يعني l > L addEventHandler ("onClientGUIClick", root, function() if ( source == GUIEditor_Button[2] ) then triggerServerEvent("login",getLocalPlayer(), guiGetText(user), guiGetText(pass)) end end ) الى : addEventHandler ("onClientGUIClick", root, function() if ( source == GUIEditor_Button[2] ) then triggerServerEvent("Login",getLocalPlayer(), guiGetText(user), guiGetText(pass)) end end ) Link to comment
iPrestege Posted July 7, 2013 Share Posted July 7, 2013 لاتستخدم كود bb لـ السنتر @ الهآجري يخرب كودك -_-" ؟ Link to comment
ABO-SR777777A Posted July 7, 2013 Author Share Posted July 7, 2013 ليش؟ طيب يلا الحل! Link to comment
ABO-SR777777A Posted July 7, 2013 Author Share Posted July 7, 2013 لاتستخدم كودbb لـ السنتر @ الهآجري يخرب كودك -_-" ؟ Link to comment
ABO-SR777777A Posted July 7, 2013 Author Share Posted July 7, 2013 طيب اذا كتبت الاسم والرقم صح ماتختفي النافذه ليش؟ وكود REGISTER addEvent("register",true) addEventHandler("register",root, function(player,userName,Password) if ( password ~= "" and password ~= nil ) then local accountAdded = addAccount( getPlayerName(source), password ) if ( accountAdded ) then outputChatBox ( "Thank you " .. getPlayerName(source) .. ", you're now registed, you can login with /login", source ) else outputChatBox ( "Error creating account, contact the server admin", source ) end else outputChatBox ( "Error creating account, correct syntax: /register ", source ) end end addCommandHandler ( "register", registerPlayer ) الى سويته وش الاخطاء الى فيه + ابي وضيفه اذا دخل السيرفر الشاشه سوده يسجل دخول ويدخل Link to comment
فاّرس Posted July 7, 2013 Share Posted July 7, 2013 (edited) ABO-SR777777A @ سوي ترايقر للكلنت وسوي اخفاء للنافذه ذذ , triggerClientEvent + احس انك نسخ ولصق وش جاب الكوماند ذذ حطيته اول كذا ,guiSetEnabled(guiGetVisible(Window)) لكن شفت الويكي ناقص ارقومنت ذذ guiGetVisible(Window) guiElement اقصد انه بالويكي , bool guiSetEnabled ( element guiElement, bool enabled ) توقعت انه لازم احط الحاله - true or false ._. + حطيت مثال على نافذه ذذ Edited July 7, 2013 by Guest Link to comment
ABO-SR777777A Posted July 7, 2013 Author Share Posted July 7, 2013 ABO-SR777777A @سوي ترايقر للكلنت وسوي اخفاء للنافذه ذذ , triggerClientEvent حطيته اول كذا ,guiSetEnabled(guiGetVisible(Window)) لكن شفت الويكي ناقص ارقومنت ذذ guiGetVisible(Window) guiElement اقصد انه بالويكي , bool guiSetEnabled ( element guiElement, bool enabled ) توقعت انه لازم احط الحاله - true or false ._. + حطيت مثال على نافذه ذذ وش يعني ترايقر وشش يفيد هذا حق وش Link to comment
فاّرس Posted July 7, 2013 Share Posted July 7, 2013 (edited) الترايقر فايدته انك تسوي شيء يكون بالسيرفر بس فـ ترسل ترايقر من الكنلت للسيرفر واذا كان شيء كلنت وانت كودك سيرفر ترسل ترايقر من السيرفر للكنت , انت تسوي له بعد ما يسجل الدخول , triggerClientEvent( "Hide",root) + تجيب الترايقر من الكلنت , Edited July 7, 2013 by Guest Link to comment
Recommended Posts