3NeD Posted July 24, 2013 Share Posted July 24, 2013 آلسلآم عليكم .. هذآ فنكشن يوم آضغط آنتر يسوي لي سيت آليمنت ..... function enterTheDimension( Key ) if Key == 'enter' then setElementDimension( localPlayer, gTable[i].dimension ); end end bindKey( 'enter', 'down', enterTheDimension ); يطلع لي خطا بآلديبوق bad argument 'setElementDimension' Link to comment
فاّرس Posted July 24, 2013 Share Posted July 24, 2013 (edited) الحين , gTable.dimension = وين معرفه؟ if Key == 'enter' then = ليه مسوي شرط وانت اصلا حاط المفتاح انتر ؟ Edited July 24, 2013 by Guest Link to comment
3NeD Posted July 24, 2013 Author Share Posted July 24, 2013 مآ عرفته .. لآني طلبت كود لآ ضغطت آنتر يدخلك على عآلم وهمي على حسب آلسيت كآميرآ آللي مسويه .. وعطآني هآلكود Blaawee آلله يجزآه خير .. وتعرفنآ مبتدئين , آتمنى تشرح لي Link to comment
فاّرس Posted July 24, 2013 Share Posted July 24, 2013 وكيف نساعدك وما طرحت الكود , اطرحه كامل ذذ ووش تبي تسوي بالضبط ذذ Link to comment
3NeD Posted July 24, 2013 Author Share Posted July 24, 2013 local gTable = { [ 1 ] = { text = 'DeathMatch', x = -2408.548828125, y = -592.69372558594, z = 134.22239685059, lookAtX = -2463.1628417969, lookAtY = -513.2041015625, lookAtZ = 107.7894744873 }, [ 2 ] = { text = 'Shooter', x = -2409.2395019531, y = -596.15222167969, z = 134.86294555664, lookAtX = -2328.9147949219, lookAtY = -542.35815429688, lookAtZ = 109.28689575195 }, [ 3 ] = { text = 'DD', x = -2402.6794433594, y = -602.47106933594, z = 134.3514251709, lookAtX = -2322.3547363281, lookAtY = -548.67700195313, lookAtZ = 108.77537536621 }, [ 4 ] = { text = 'Old School', x = -2401.1706542969, y = -603.57043457031, z = 135.20037841797, lookAtX = -2347.8125, lookAtY = -680.43634033203, lookAtZ = 99.922225952148 } }; local i = 1; local screen = { guiGetScreenSize( ) }; function swingBettwenArrow( key ) if key == 'arrow_l' then if i == 1 then i = #gTable; else i = i - 1; end else if i == #gTable then i = 1; else i = i + 1; end end fadeCamera( true ); end bindKey ( 'arrow_l', 'down', swingBettwenArrow ); bindKey ( 'arrow_r', 'down', swingBettwenArrow ); function enterTheDimension( Key ) if Key == 'enter' then setElementDimension( localPlayer, gTable[i].dimension ); end end bindKey( 'enter', 'down', enterTheDimension ); addEventHandler( 'onClientRender', root, function( ) dxDrawText( gTable[i].text, screen[ 1 ] / 2 - dxGetTextWidth( gTable[i].text, 1, 'arial' ) / 2, screen[ 2 ] / 2 + 128, screen[ 1 ], screen[ 2 ], tocolor( 255, 255, 255, 255), 1, 'arial', 'left', 'top', false, false, false, true ); setCameraMatrix( gTable[i].x, gTable[i].y, gTable[i].z, gTable[i].lookAtX, gTable[i].lookAtY, gTable[i].lookAtZ ); end ); آبيه يوم تضغط سهم يمين يسوي لك SetCameraMatrix ويوم تضغط انتر يشوف آلمآتركس حقك ويدخلك على عآلم وهمي ( كل مآتركس له عآلم) Link to comment
فاّرس Posted July 24, 2013 Share Posted July 24, 2013 (edited) local gTable = { [ 1 ] = { text = 'DeathMatch', x = -2408.548828125, y = -592.69372558594, z = 134.22239685059, lookAtX = -2463.1628417969, lookAtY = -513.2041015625, lookAtZ = 107.7894744873, dimension = 1 }, [ 2 ] = { text = 'Shooter', x = -2409.2395019531, y = -596.15222167969, z = 134.86294555664, lookAtX = -2328.9147949219, lookAtY = -542.35815429688, lookAtZ = 109.28689575195, dimension = 2 }, [ 3 ] = { text = 'DD', x = -2402.6794433594, y = -602.47106933594, z = 134.3514251709, lookAtX = -2322.3547363281, lookAtY = -548.67700195313, lookAtZ = 108.77537536621,dimension = 3 }, [ 4 ] = { text = 'Old School', x = -2401.1706542969, y = -603.57043457031, z = 135.20037841797, lookAtX = -2347.8125, lookAtY = -680.43634033203, lookAtZ = 99.922225952148,dimension = 4 } }; local i = 1; local screen = { guiGetScreenSize( ) }; function swingBettwenArrow( key ) if key == 'arrow_l' then if i == 1 then i = #gTable; else i = i - 1; end else if i == #gTable then i = 1; else i = i + 1; end end fadeCamera( true ); end bindKey ( 'arrow_l', 'down', swingBettwenArrow ); bindKey ( 'arrow_r', 'down', swingBettwenArrow ); function enterTheDimension( Key ) if Key == 'enter' then setElementDimension( localPlayer, gTable[i].dimension ); end end bindKey( 'enter', 'down', enterTheDimension ); addEventHandler( 'onClientRender', root, function( ) dxDrawText( gTable[i].text, screen[ 1 ] / 2 - dxGetTextWidth( gTable[i].text, 1, 'arial' ) / 2, screen[ 2 ] / 2 + 128, screen[ 1 ], screen[ 2 ], tocolor( 255, 255, 255, 255), 1, 'arial', 'left', 'top', false, false, false, true ); setCameraMatrix( gTable[i].x, gTable[i].y, gTable[i].z, gTable[i].lookAtX, gTable[i].lookAtY, gTable[i].lookAtZ ); end ); شوف عندك , سطر 3 و4 و5 و6 dimension = 1 dimension = 2 dimension = 3 dimension = 4 الي عليك تغير رقم العالم الوهمي ذذ Edited July 24, 2013 by Guest Link to comment
فاّرس Posted July 24, 2013 Share Posted July 24, 2013 بآي سطر بآلضبط قصدك ؟! شوف عندك , سطر 3 و4 و5 و6 dimension = 1 dimension = 2 dimension = 3 dimension = 4 غير الارقام للعالم الي تبيه لكل ماتركس ذذ Link to comment
3NeD Posted July 24, 2013 Author Share Posted July 24, 2013 نفس آلخطأ حبيبي .. ( bad argument 'setElementDimension ) Link to comment
فاّرس Posted July 24, 2013 Share Posted July 24, 2013 /جرب انسخه مره ثانيه اظن كان في خططأ بـ Link to comment
3NeD Posted July 24, 2013 Author Share Posted July 24, 2013 يب آنتبته للـ / وحذفتهآ .. نفس آلشيء .. Link to comment
./BlackBird# Posted July 24, 2013 Share Posted July 24, 2013 الكود مافيه شي شغال وش يطلع عندك؟ Link to comment
3NeD Posted July 24, 2013 Author Share Posted July 24, 2013 شغآل بس يوم تضغط آنتر مآ يدخلك ع آلعآلم آلوهمي وللمعلوميه آلعآلم آلوهمي شغآل وميه ميه .. Link to comment
فاّرس Posted July 24, 2013 Share Posted July 24, 2013 شغآل بس يوم تضغط آنتر مآ يدخلك ع آلعآلم آلوهميوللمعلوميه آلعآلم آلوهمي شغآل وميه ميه .. شوف الادمنيه اذا تغير ولا لا؟ وجرب طف المود او احذفه وركبه مره ثانيه ذذ Link to comment
3NeD Posted July 24, 2013 Author Share Posted July 24, 2013 ججربت كل شي .. غيرت آلآرقآم حقت آلعوآلم كلهآ نفس آلخطأ Link to comment
فاّرس Posted July 25, 2013 Share Posted July 25, 2013 %100 المشكله من عندك انا عندي شغال Link to comment
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