iPrestege Posted October 9, 2012 Share Posted October 9, 2012 بسم الله الرحمن الرحيم السلام عليكم ورحمة الله وبركاتة ~ طلبي هو كود آظهار المال في الفري روم نفس البنق وشرح المكان واذا كان نفس البنق مايحتاج شرح الاكواد بس >< والسلآم عليكم ورحمة الله وبركاتة ~ فهد Link to comment
abu5lf Posted October 9, 2012 Share Posted October 9, 2012 مادام انت حاط البنق هي نفس الطريقة بس استخدم getPlayerMoney Link to comment
iPrestege Posted October 9, 2012 Author Share Posted October 9, 2012 الي فهمتة من الكود واللي لقيتة بس السيرفر ؟ اللي هوو النفكشن اللي يوضع بالسيرفر : function checkMoney(thePlayer, command) local money = getPlayerMoney(thePlayer) -- get the amount of money from the player who entered the command if (money > 1000) then -- if money is more than 1000 outputChatBox("You are rich: " .. tostring(money), thePlayer) -- output this message together with the money else outputChatBox("Poor guy...", thePlayer) -- and else, output this message end end addCommandHandler("checkMoney", checkMoney) + الكلنت مآلقيتة >< Link to comment
iPrestege Posted October 9, 2012 Author Share Posted October 9, 2012 ياريت تطرح انت الاكواد مثل طريقتي >< يعني كود سيرفر كود كلنت > توني بادي آبرمج >< Link to comment
abu5lf Posted October 9, 2012 Share Posted October 9, 2012 لا مايحتاج كل هذي الكلنت هيك local playerMoney = getPlayerMoney ( ) playerMoney == فلوسك Link to comment
iPrestege Posted October 9, 2012 Author Share Posted October 9, 2012 >< الكود مايجي لبل مثل الاسم والبنق الاسم والبنق اضفتهم فوق الكيل >< ابي اضيف المآل >< بس مافهمت الكود صح >< يختلف عن الاسم والبنق الاسم والبنق {'lbl', id='YourName', text = 'اسمكـ:'}, {'lbl', id='name', text='', width=150}, {'lbl', id='YourPing', text = 'بنقكـ:'}, {'lbl', id='ping', text='', width=45}, هذا فوق الازرار + المال يختلف ؟ >< لآني مآفهمت الكود >< Link to comment
iPrestege Posted October 9, 2012 Author Share Posted October 9, 2012 + الكلنت حق الاسم والبنق : function updatePing() local ping = getPlayerPing(g_Me) setControlText(wndMain, 'ping', ping ) setControlText(wndMain, 'name', tostring(string.gsub(getPlayerName(g_Me),'#%x%x%x%x%x%x', ''))) end ذذ >< يختلف عن الفلوس Link to comment
abu5lf Posted October 9, 2012 Share Posted October 9, 2012 function updateMoney() local PlayerMoney = getPlayerMoney() setControlText(wndMain, 'Money', PlayerMoney ) end مافيه فرق ملاحظة : انا معرف اعدل الفري روم Link to comment
iPrestege Posted October 9, 2012 Author Share Posted October 9, 2012 ذذ ننتظر تآبل ذذ Link to comment
hassan.k.s.a Posted October 9, 2012 Share Posted October 9, 2012 الأكواد منقوله من موضوع آخر الأكواد لـ سعد لاكن مع التعديل جرب هذا ---- أول شي تروح الى ازرار ال wndMain تضيف فوق زر انتحار او kill فوق هذا الزر {'btn', id='kill', onclick=killLocalPlayer}, تحط {'lbl', id='Your Money:'}, {'lbl', id='Money', text='', width=45}, {'br'}, كذا خلصنا من الأزار --------------------------------------- يبقى لنا عمل الوظيفه تطلع فوق تحط هذي الوظيفه function updatePing() local Money = getPlayerMoney(g_Me) setControlText(wndMain, 'Money', Money ) end بعدين تدور على هذي الوظيفه تحطه بنفس الوظيفه function mainWndShow() ---تحطه هنا هذا اللي تحطه updateMoney = updateMoney or setTimer(updateMoney, 2000, 0) يصير كذا function mainWndShow() if not getPedOccupiedVehicle(g_Me) then hideControls(wndMain, 'repair', 'flip', 'upgrades', 'color', 'paintjob', 'lightson', 'lightsoff') end updateTimer = updateTimer or setTimer(updateGUI, 2000, 0) updateMoney = updateMoney or setTimer(updateMoney, 2000, 0) ---اhere updateGUI(true) end ----------------------- بعدها تدور على اسم الوظيفه ذي function mainWndClose() ---تحطه هنا هذا اللي تحطه killTimer(updateMoney) updateMoney = nil يصير كذا function mainWndClose() killTimer(updateTimer) updateTimer = nil killTimer(updateMoney) ---here updateMoney = nil ---here colorPicker.closeSelect() end Link to comment
iPrestege Posted October 9, 2012 Author Share Posted October 9, 2012 ^^ تسلم حسن عالافادة تم اضافة المال بنجاح ! هذا اللي اقصدة >< Link to comment
iPrestege Posted October 9, 2012 Author Share Posted October 9, 2012 عاشق الكود صحيح ! Link to comment
hassan.k.s.a Posted October 9, 2012 Share Posted October 9, 2012 عاشق الكود صحيح ! وبعدين وش كنت انت تقصد ؟ ماعليك من عاشق الله يهديه ماعنده الا خطأ مافي الا هو صح Link to comment
abu5lf Posted October 9, 2012 Share Posted October 9, 2012 ماجبت شي من راسي شف Syntax Client https://wiki.multitheftauto.com/wiki/GetPlayerMoney Link to comment
hassan.k.s.a Posted October 9, 2012 Share Posted October 9, 2012 ماجبت شي من راسي شف Syntax Client https://wiki.multitheftauto.com/wiki/GetPlayerMoney تسلم لاكن الكود شغال ومو لازم التدقيق ^.^ 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