iPrestege Posted May 22, 2013 Posted May 22, 2013 بسم الله الرحمن الرحيم السلام عليكم و رحمة الله وبركاتة ( Parameters ) ماهو الـ : Parameters Parameters : هي عدهـ اشياء مرتبطة بـ الحدث آمثلة : الحدث ( onPlayerLogin ) : البارتمنت الثاني هو اللي سججل فية الاعب الحساب دخوله .. : addEventHandler("onPlayerLogin",root, function ( _,account ) if getAccountName ( account ) == "Prestege" then outputChatBox("* Prestege Logged in",root) end end ) الوظيفة : getAccountName تتطلب وظيفة : Account Player = getPlayerAccount و بـ الحدث عند تسجيل دخول الاعب الحساب معرف الحساب اللي توهـ سجل دخوله فية .. طبعا من الويكي : theCurrentAccount: The account the player logged into just now مثآل آخر : الحدث ( onPlayerDamage ) : addEventHandler("onPlayerDamage",root, function ( attacker ) if ( attacker and attacker ~= source and getElementType ( attacker ) == "player" ) then takePlayerMoney ( attacker , math.random ( 100,50000 ) ) end end ) نشوف فـ الحدث عندنا بارتمنت الـ ( attacker ) : الـ attacker = ? وش هو اصلا ? الاتاكر هو اللي هاجم اللاعب .. من الويكي : attacker: A player element representing the player who was the attacker. If there was no attacker this returns false. و طبعا هذي مجرد امثلة بسيطة ! لـ التوضيح فقط لاني اشوف الناس الصراحة بعضها ماهي عارفة البارتمنت وش هو تنبية : شرط اساسي فتح صفحة الويكي .. :') تنبية : ماهو لازم يكون نفس الاسم اللي بالويكي مجرد الترتيب هو المهم .. إن أصبت فمن الله وإن أخطأت فمن نفسي والشيطان
iPrestege Posted May 23, 2013 Author Posted May 23, 2013 برستيج شنو يعني ( _,account ) _ هذا يعني تاخذ مكان شيء لانة فية بارتمنت قبل الاكاونت ذذ _,account
S4MuEL Posted May 23, 2013 Posted May 23, 2013 شكرَآ ع آلششرحح .. لكن إذآ حططينآ بدآل , ( _,account ) ذي .. ( account ) عآدي ؟ ! ..
PaiN^ Posted May 25, 2013 Posted May 25, 2013 _ هذي حطها لتخطي برامتر ما يبي يستخدمه إسم البراميتر مو لازم يكون زي الويكي, لكن الترتيب لازم لو تشوف الويكي ترتيب البراميتر للحدث إللي إستخدمه : thePreviousAccount : guest هذا يعني الحساب السابق أو القديم, هو غالبا يكون حساب ضيف theCurrentAccount : هذا الحساب إللي سجلت دخول عليه و حنا نبغى الحساب إللي سجلت دخول عليه, عشان كذا تخطينا الحساب القديم إللي هو البراميتر الأول بإستخدام _ و رحنا على البراميتر الثاني إللي هو الحساب الجديد
iMr.Dawix~# Posted May 23, 2014 Posted May 23, 2014 _,هذي تستخدم للتعويض بدال شي برستيج شنو يعني ( _,account ) _ هذا يعني تاخذ مكان شيء لانة فية بارتمنت قبل الاكاونت ذذ _,account
Ahmadhani Posted May 24, 2014 Posted May 24, 2014 ممكن تشرحلي هذي كيف سويتها يعني كيف if ( attacker and attacker ~= source and getElementType ( attacker ) == "player" ) then وذي بعد if getAccountName ( account ) == "Prestege" then
iMr.Dawix~# Posted May 24, 2014 Posted May 24, 2014 ممكن تشرحلي هذي كيف سويتها يعني كيف if ( attacker and attacker ~= source and getElementType ( attacker ) == "player" ) then وذي بعد if getAccountName ( account ) == "Prestege" then م ادري وش تقصد بس لو تقصد شرحها الأولى : .اذا كان الي يضر موجود و اذا كان الي يضر مهو الي متضرر واذا كان نوعه لاعب والثثانية ."Prestege"يتأكد اذا كان اسم الحساب
Max+ Posted June 2, 2014 Posted June 2, 2014 addEventHandler("onPlayerJoin",root, function (thePlayer) if getAccountName ( thePlayer ) == "Prestege" then givePlayerMoney ( thePlayer , math.random ( 100,50000 ) ) outputChatBox( thePlayer, "Thank's For the Lesson", getRootElement, 255, 255,0 ) end end )
shwaeki Posted June 2, 2014 Posted June 2, 2014 addEventHandler("onPlayerJoin",root, function (thePlayer) if getAccountName ( thePlayer ) == "Prestege" then givePlayerMoney ( thePlayer , math.random ( 100,50000 ) ) outputChatBox( thePlayer, "Thank's For the Lesson", getRootElement, 255, 255,0 ) end end ) thePlayer حط بدل هاي source لانة غير معرف
Max+ Posted June 2, 2014 Posted June 2, 2014 addEventHandler("onPlayerJoin",root, function (thePlayer) if getAccountName ( thePlayer ) == "Prestege" then givePlayerMoney ( thePlayer , math.random ( 100,50000 ) ) outputChatBox( thePlayer, "Thank's For the Lesson", getRootElement, 255, 255,0 ) end end ) thePlayer حط بدل هاي source لانة غير معرف بالضبط كشفتها هههههههههههههههههههههه ماشاء الله عليك
shwaeki Posted June 2, 2014 Posted June 2, 2014 عشين تتحقق من الحساب لازم حساب الاعب مو الاعب عشين هيك استخدم هاي local acc = getPlayerAccount(source ) if getAccountName ( acc ) == "Prestege" then
Max+ Posted June 2, 2014 Posted June 2, 2014 عشين تتحقق من الحساب لازم حساب الاعب مو الاعب عشين هيك استخدم هاي local acc = getPlayerAccount(source ) if getAccountName ( acc ) == "Prestege" then وتقدر تختصرها زي كذا افضل , addEventHandler("onPlayerLogin",root, function (account) if getAccountName(getPlayerAccount(account) == 'Prestege' ) then givePlayerMoney ( source , math.random ( 100,50000 ) ) outputChatBox( source, "Thank's For the Lesson", getRootElement, 255, 255,0 ) end end )
#DRAGON!FIRE Posted June 2, 2014 Posted June 2, 2014 عشين تتحقق من الحساب لازم حساب الاعب مو الاعب عشين هيك استخدم هاي local acc = getPlayerAccount(source ) if getAccountName ( acc ) == "Prestege" then اكيد ما شفت الشرح .. في بارتمنت بالحدث نفسه الحساب اللي دخل فيه اللاعب ما يحتاج تستخدم ذا .
K1NG Posted June 2, 2014 Posted June 2, 2014 عشين تتحقق من الحساب لازم حساب الاعب مو الاعب عشين هيك استخدم هاي local acc = getPlayerAccount(source ) if getAccountName ( acc ) == "Prestege" then وتقدر تختصرها زي كذا افضل , addEventHandler("onPlayerLogin",root, function (account) if getAccountName(getPlayerAccount(account) == 'Prestege' ) then givePlayerMoney ( source , math.random ( 100,50000 ) ) outputChatBox( source, "Thank's For the Lesson", getRootElement, 255, 255,0 ) end end )
iMr.Dawix~# Posted June 2, 2014 Posted June 2, 2014 outputChatBox( thePlayer, "Thank's For the Lesson", getRootElement, 255, 255,0 )
#DRAGON!FIRE Posted June 2, 2014 Posted June 2, 2014 عشين تتحقق من الحساب لازم حساب الاعب مو الاعب عشين هيك استخدم هاي local acc = getPlayerAccount(source ) if getAccountName ( acc ) == "Prestege" then وتقدر تختصرها زي كذا افضل , addEventHandler("onPlayerLogin",root, function (account) if getAccountName(getPlayerAccount(account) == 'Prestege' ) then givePlayerMoney ( source , math.random ( 100,50000 ) ) outputChatBox( source, "Thank's For the Lesson", getRootElement, 255, 255,0 ) end end ) مسوي هريسة تراكـ اولأ ليه getPlayerAccount ؟ ثانيا outputChatBox( source, "Thank's For the Lesson", getRootElement, 255, 255,0 ) ناقص القوسين حق getRootElement بعدين مدام حاتط روت ليه تحط سورس ؟ .. وليه حاتط سورس اصلن بالبداية اول ارقمنت هو التكست من وين جبت سورس ؟
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