Jump to content

مساعدة


Recommended Posts

سلام عليكم حاجات بسيطة عايزة واكون خلصت سيرفرى

عارف انى بطلب اشياء كتير بس  ادينى بتفاعل فى القسم

:D

المهم انا عايز اضيف ان اللاعب يحصل على سلاح اما يسجل  هو مكتوب انة ياخد ربع مليون عايز اضيف ياخد سلاح ام فور 100 طلقة ماثلا  انا كتبت الكود

اعرفة بسيط بس مانفع


addEvent ( 'CreateAccount_' , true )
addEventHandler ( 'CreateAccount_' , getRootElement ( ) ,
function ( aAccountName , aAccountPassword , Year , Month , Day )
logOut ( source )
	local aAccount_ = getAccount ( tostring( aAccountName ) )
		if ( aAccount_ == false ) then
			local aAccount_1 = addAccount( tostring( aAccountName ) , tostring( aAccountPassword ) )
			if ( aAccount_1 ) then
				logIn ( source , aAccount_1 , aAccountPassword )
				executeSQLQuery( 'INSERT INTO aAccountss___ VALUES ( ? , ? , ? , ? , ? , ? )' , aAccountName , aAccountPassword , getPlayerSerial ( source ) , Year , Month , Day )
				setAccountData ( getPlayerAccount ( source ) , 'Account:Bank' , 0 )
				triggerClientEvent ( source , 'Remove:PanelLogin' , source , tostring( aAccountName ) , tostring( aAccountPassword ) )
				spawnPlayer ( source , -2405, -598, 132.65 )
				fadeCamera ( source , true )
				setElementData ( source , 'Money' , 250000 )
				exports['guimessages']:outputServer( source, '#FFFFFF[Mafia War] #00FF4DIt was set up your account and give you the amount of #FF0000: #00FF4D$1,000,000' , 255, 255, 255 )
			end
		else
		exports['guimessages']:outputServer( source, '#FFFFFF[Mafia War حرب المافيا]#FF0000 This account already exists' , 255, 255, 255 )
	end
end )

 

شى اخير عايز اما اللاعب يقتل اللاعب يحصل على نجوم ماعدا الشرطى يعنى ميكنشى الشرطى يقتل واحد فايحصل هو كمان على نجوم لان شخص عملها ليا  هنا ماظبطت

الشرطى لو قتل مايجيلوة نجوم  وشى اخير اما اللاعب يموت تنحذف نجوم

وكدة ا ناقص الاستضافة وخلاص

Link to comment
  • Scripting Moderators

استخدم فنكشن

giveWeapon
لإعطاء سلاح للاعب

بالنسبة للسؤال الثاني
إستخدم حدث
onPlayerWasted
وتحقق ان الاعب مو بفريق الشرطة
getPlayerTeam
setPlayerWantedLevel واعطيه النجوم

Edited by xLive
نسيت فنكشن النجوم
Link to comment
  • Scripting Moderators

جرب مره بسيط

خش ع كل فنكشن وشوف الصيغة حقته وتحت فيه مثال

وارسل محاولتك وبنصحح لك وبتعرف اخطائك عشان تتعلم


 

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...