MANAMAY Posted December 31, 2012 Share Posted December 31, 2012 function createVehicleForPlayer(thePlayer, command, vehicleModel) end addCommandHandler("createvehicle", createVehicleForPlayer) ذا الكود صح؟ Link to comment
abu5lf Posted December 31, 2012 Share Posted December 31, 2012 function createVehicleForPlayer(thePlayer, command, vehicleModel)end addCommandHandler("createvehicle", createVehicleForPlayer) ذا الكود صح؟ انت ناسخه من الويكي ناقص هذي تكملته function createVehicleForPlayer(thePlayer, command, vehicleModel) local x,y,z = getElementPosition(thePlayer) -- الحصول على احداثيات لاعب x = x + 5 -- x زيادة 5 الى local createdVehicle = createVehicle(tonumber(vehicleModel),x,y,z) -- التحقق من الرد اذا كان خاطئ if (createdVehicle == false) then -- اذا كان التحقق صحيح اخراج النص التالي للأعب فقط outputChatBox("Failed to create vehicle.",thePlayer) end end addCommandHandler("createvehicle", createVehicleForPlayer) Source: Scripting_Introduction 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