-
Posts
905 -
Joined
-
Last visited
Everything posted by TwiX!
-
nothing news please use tabulation! your system not really check accounts, just settimer with outputchatbox
-
learn arguments what its 'source' in https://wiki.multitheftauto.com/wiki/OnColShapeHit source in your code - its player? or object thePlayer too
-
search there https://community.multitheftauto.com/index.php?p=resources&s=list MODERATOR NOTE FOR KNOWNLEDGEBASE, Answer: https://community.multitheftauto.com/index.php?p=resources&s=details&id=14911
-
Если у тебя проблемы с англ. языком, то забудь про скриптинг и учи англ. Удалено может хватит посты набивать?
-
сделать им скидку на вещи эти, или отдельные преимущества, которых нет у простых пользователей например донатор сменить цвет тачки может, а простой нет
-
no one will make it for you. check this links, its help + https://community.multitheftauto.com/index.php?p=resources
-
looks cool, good edit
-
Зачем получать позицию,если мы аттачим? прочитай аргументы attachElements
-
сделай проверку для всех игроков
-
https://wiki.multitheftauto.com/wiki/AttachElements
-
да вроде бы всё нормально зачем тебе нужны таймеры которые работают постоянно? сделай маркер ( или типо того) когда игрок подъезжает к точке, лифт начинает работать
-
потерял скобку и end --[[Donat]] --Создаём префикс для чата. function vipchat(text, msgtype) local root = getRootElement() local account = getAccountName(getPlayerAccount(source)) local name = getPlayerName(source) if (msgtype == 0) then if isObjectInACLGroup("user." .. account, aclGetGroup("VIP")) then outputChatBox("#855863[ВИП] #FFFFFF" .. name .. ":#FFFFFF " .. text, root, 255, 255, 0, true) end end end addEventHandler("onPlayerChat", root, vipchat) --Окей,создаём функцию,которая даёт деньги ВИПу. function vipfunc () local account = getAccountName(getPlayerAccount(source)) if isObjectInACLGroup("user." .. account, aclGetGroup("VIP")) then givePlayerMoney(source, 10000) end end addCommandHandler("vipmoney",vipfunc) --[[ Делаем его невидимым.Спасибо Flaker'у за ресурс. ]] local teams = { "Red", "Blue" } local groups = { "VIP" } blip = { } function toggleInvis ( source ) local nameTag = getPlayerNametagText ( source ) if ( source and getElementType ( source ) == "player" and hasPlayerAccessToInvisible (source) == true ) then if ( getElementAlpha ( source ) > 200 ) then setPlayerNametagShowing ( source, false ) setElementAlpha ( source, 0 ) local attachedElements = getAttachedElements ( source ) for ElementKey, ElementValue in ipairs ( attachedElements ) do if ( getElementType ( ElementValue ) == "blip" ) then destroyElement ( ElementValue ) end end outputChatBox ( "#FFFF00*Инфо* #00FF00Невидимость включена", source, 0, 255, 0, true ) else setPlayerNametagShowing ( source, true ) setElementAlpha ( source, 255 ) local nameTag = getPlayerName ( source ) local r, g, b = getPlayerNametagColor ( source ) blip [ source ] = createBlipAttachedTo ( source, 0, 2, r, g, b, 255 ) outputChatBox ( "#FFFF00*INFO* #00FF00Невидимость выключена", source, 0, 255, 0, true ) end else outputDebugString ( "Player: ".. nameTag .." try to use invisible, but he hasn't access to it!" ) end end addCommandHandler ( "invisible", toggleInvis ) function hasPlayerAccessToInvisible (thePlayer) -- Делаем проверки local allowed = false if ( thePlayer ) then for id, team_cur in ipairs(teams) do if ( getPlayerTeam ( thePlayer ) and getTeamName ( getPlayerTeam ( thePlayer ) ) == team_cur ) then allowed = true break end end if not(allowed == true) then for id, group_cur in ipairs(groups) do if ( isObjectInACLGroup ( "user.".. getAccountName ( getPlayerAccount ( thePlayer ) ), aclGetGroup ( group_cur ) ) ) then allowed = true break end end end return allowed end end addEventHandler ( "onPlayerQuit", root, -- Когда он выходит - уничтожать блип function ( ) if isElement ( blip [ source ] ) then destroyElement ( blip [ source ] ) end end ) addEventHandler ( "onPlayerLogout", root, -- Когда он выходит из аккаунта - уничтожать блип function ( ) if isElement ( blip [ source ] ) then destroyElement ( blip [ source ] ) end end )
-
выглядит прикольно, оригинально
-
с днюхой) всех благ
-
первый раз слышу
-
прикрепи машину к объекту, который поднимается
-
MAN THERE AINT NO ****ING ERRORS! you not understand outputDebugString example function test (thePlayer) local imOtherFunction = getPlayerName(thePlayer) if imOtherFunction then blablabla() end end check it : function test (thePlayer) local imOtherFunction = getPlayerName(thePlayer) outputDebugString ('imotherfunction created') if imOtherFunction then blablabla() outputDebugString ('imOtherFunction passed') end end function blablabla() outputDebugString ('passed') end
-
skotinka style.. dont like
-
Привет всем не 1 раз видел туториалы на английском форуме Здесь я покажу как сделать прыжок для машины на DM,DD или прочих модах Надо же с чего то начинать и для Русского Сообщества Прошу модераторов сделать отдельный форум под Туториалы или Учебник (Обучение как вам угодно) - Чтобы каждый мог добавить туда свой тут. да и сделать поиск проще И так: local Markers = { [createMarker(-2405,-598,132.6484375,"cylinder",1.5,255,250,110,100)] = 1, -- 1 это сила прыжка [createMarker(-2405,-588,132.6484375,"cylinder",1.5,255,250,110,100)] = 7, -- 7 это сила прыжка [createMarker(-2405,-578,132.6484375,"cylinder",1.5,255,250,110,100)] = 4 -- 4 это сила прыжка } addEventHandler("onClientMarkerHit",root, function(element) if element == localPlayer and isPedInVehicle(element) and Markers[source] then local vehicle = getPedOccupiedVehicle(element) local x,y,z = getElementVelocity(vehicle) setElementVelocity(vehicle,x,y,z+Markers[source]) end end ) Markers - Это таблица где хранятся наши маркеры Далее сама фунция если елемент(игрок) это локальный игрок(т.е это вы, а не какой-то левый)и этот локальный игрок в машине, и созданны маркеры то получаем автомобиль игрока получаем его координаты устанавливаем сам прыжок vehicle = машина x - точка x y - точ y z - точ z + прибавляем к его точки z (Markers - наши маркеры[Если сказать прямо то это маркер на который заехал игрок]) Подробно тут https://wiki.multitheftauto.com/wiki/Eve ... ent_source Или viewtopic.php?f=141&t=37420 Таблицы http://www.lua.org/pil/2.5.html Так же https://wiki.multitheftauto.com/wiki/OnClientMarkerHit Ну и https://wiki.multitheftauto.com/wiki/CreateMarker P.S Поправьте меня, если я где то не прав, или дополните меня Очень прошу не разводить здесь флуд. Каждый может ошибиться Так же можно добавить под разделы (Лёгкие и Сложные) Данный тип относится к лёгкому
-
man pls check your all code with debug or output messages. in all your posts not have errors..
-
идея с плюсами или кнопкой спасибо, помогла бы всем действительно упрощает поиск ладно если попадётся тема где всего 2-3 страницы в поиске, а если их 400? искать ответ там очень долго можно сделать страницу, где можно посмотреть всех разработчиков. и т.д P.S "юзерам стремится некуда." повышать свои навыки, помогая другим, повышать репутацию (если ты скриптер - и представляешь платные услуги) это на данный момент Рейтинги начнут сраться 2 школьница (если только 2..) засрут репутацию другому, будет -50 репа и т.д или просить поставь мне плюсик (появится флуд, тоже плохо) сначала надо улучшить форум свести к минимуму (тролинг. и т.д) потом уже создавать систему репутации
-
Авто обновление клиента игрока при входе на сервер
TwiX! replied to DarkangelS's topic in Помощь / Отчеты об ошибках
-
Авто обновление клиента игрока при входе на сервер
TwiX! replied to DarkangelS's topic in Помощь / Отчеты об ошибках
https://wiki.multitheftauto.com/wiki/GetPlayerVersion https://wiki.multitheftauto.com/wiki/GetVersion local ver = getVersion ().sortable local type = string.sub( ver, 7, 7 ) local build = string.sub( ver, 9, 13 ) if build < "02888" and type ~= "1" or ver < "1.1.0" then outputChatBox( "Resource is not compatible with this client." ) outputChatBox( "Please get latest 1.1 nightly from nightly.multitheftauto.com" ) return end