Jump to content

PauloCascus

Members
  • Posts

    57
  • Joined

  • Last visited

Everything posted by PauloCascus

  1. возможно... а может с позицией колшейпа накасячил
  2. Just i want to fix and improve this script to use shaders, but not easing functions...
  3. Кажется видел, что у вас проблема с тем, что кто то может узнать команду и использовать ее Если ГМ нужен только для админов или випов То вам нужно производить запуск функции через тригер с серверной стороны Серверная сторона function adminGMon() local accName = getAccountName( getPlayerAccount(source)) if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then triggerClientEvent( source, "onClientGMStart", getRootElement()) else outputChatBox("У вас нет прав на использование этой команды", source, 200, 0, 0 ) end end addCommandHandler("ongodmode", adminGMon) function adminGMoff() local accName = getAccountName( getPlayerAccount(source)) if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then triggerClientEvent( source, "onClientGMStop", getRootElement()) else outputChatBox("У вас нет прав на использование этой команды", source, 200, 0, 0 ) end end addCommandHandler("offgodmode", adminGMoff) Клиентская сторона function startgm() gmtimer = setTimer(gmforad, 2000, 0) outputChatBox ("GodMode режим был включен!",255, 0, 0,true) end addEvent("onClientGMStart", true) addEventHandler("onClientGMStart", getRootElement(), startgm) function offgm() killTimer (gmtimer) setElementData(getLocalPlayer(),"blood", 12000) outputChatBox ("GodMode режим был выключен!",255, 0, 0,true) end addEvent("onClientGMStop", true) addEventHandler("onClientGMStop", getRootElement(), offgm) function gmforad() if getElementData(getLocalPlayer(),"logedin") then setElementData(getLocalPlayer(),"blood", 500000) setElementData(getLocalPlayer(),"bleeding", 0) setElementData(getLocalPlayer(),"cold", false) setElementData(getLocalPlayer(),"temperature", 37) setElementData(getLocalPlayer(),"pain", false) setElementData(getLocalPlayer(),"brokenbone", false) setElementData(getLocalPlayer(),"thirst", 100) setElementData(getLocalPlayer(),"food", 100) end end
  4. ... i was looking for HLSL, but there are so many other formats not the same like fx and so many editors but a little count of tutorials... So shity mess...
  5. Серверная сторона предназначена для функций которые выполняет сервер, клиентская сторона для функций которые выполняет ваша MTA. http://wiki.mtasa.com/ Посмотри там, Функции бывают клиентские, серверные и те которые можно использовать на обеих сторонах в зависимости от цели. Добавь меня в скайпе проведу тебе быстрый семинар по скриптингу МТА PauloManwen
  6. попробуй сделать на клиентской стороне скорее всего у тебя игрок не определяется как thePlayer что написано в debugscript ? addEventHandler("onClientResourceStart", getRootElement(), function() setDevelopmentMode(true) end) local gate = createObject(10841, 2595.5, -2140.3000488281,6.9000000953674 ) local colshape = createColCircle ( 2595.5, -2140.3000488281, 25 ) function moveUp() if ( getElementModel(localPlayer) == 217 ) then moveObject( gate, 6000, 2618.3000488281, -2140.3000488281, 6.9000000953674, 0, 0, 0 ) else return false end end addEventHandler("onClientColshapeHit", colshape, moveUp) function moveBack() if ( getElementModel( localPlayer ) == 217 ) then moveObject( moveObject (gate, 6000, 2595.5, -2140.3000488281,6.9000000953674) else return false end end addEventHandler("onClientColShapeLeave", colshape, moveBack)
  7. thank you )) guys, i need some tutorials of camera movement and dxShaders anybody has a few links ?
  8. dx Authotization System Information about script: • dxEditboxes • dxButtons • dxError Label • dxError Highlight line • hmm.. Copyrights or advertising on the element which move Updates: [28.01.2015] Open-Source: http://community.mtasa.com/index.php?p= ... s&id=10860 Goals: • Want to add shader effects to the script instead the easing • To make it in oop ( need for the shaders ) Second version First version viewtopic.php?f=108&t=81918
  9. Hi guys I saw like a guys from different scripting teams import the models for a few vehicles of the specifiс ID: Sultan for example, i saw the Police Sultan on the server and normal, i want to know how i can to make it becouze engineLoadTXD and engineLoadDFF makes it for all cars from specific ID...
  10. So here is what you should write instead: dxDrawText( mbut.text, mbut.x, mbut.y, mbut.x + mbut.w, mbut.y + mbut.h, tocolor(0, 0, 0), sw/1600, "bankgothic", "center", "center") It should work as expected. Regards, Citizen yeah, it's working. Thanks
  11. Hello, i think this is stupid situation but what i'm doing wrong... Position of the rectangle and text is the same.. but the text has moved in other on the test. It's not once happend, every time when i've started to write my code, i had this result... local sw, sh = guiGetScreenSize() function renderMain() addEventHandler("onClientRender", getRootElement(), renderMainButtons) end addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), renderMain) mainbuttons = { { x = sw * 0.5, y = sh * 0.5, w = sw * 0.2, h = sh * 0.2, text = "Login" } } function renderMainButtons() for i, mbut in ipairs ( mainbuttons ) do dxDrawRectangle( mbut.x, mbut.y, mbut.w, mbut.h ) if mbut.text then dxDrawText( mbut.text, mbut.x, mbut.y, mbut.w, mbut.h, tocolor(0, 0, 0), sw/1600, "bankgothic", "center", "center") end end end
  12. thank you for fast answer i will try to make it )
  13. Hi guys, i have some not ordinary question: how i can to hide a part of dx element on the screen? hmm stupid question... Okay.. Everybody saw default mta scoreboard, it's using dx functions, but when the player scrolled up or down the list of the players hidding. Okay we can open the package with this scoreboard script inside the resource folder and what we looking ? js file ( Javascript ) and FX file ( idk what is it, couze i'm begginer in the programming ) So question is simple: i need to use Javascript to make dx scrolling grid list ? Or i can to use any vectors ? I think anyone who met dx in the Mta like it more then gui, but it's harder... So anyway i told not only about grid lists, but about dx functions in general I hope, u understand me It's not my native lang Thank you ))
  14. Оплата зависит от сложности написания программного кода
  15. Hello, dudes, Minase Studio RP find people to start the working for Role Play gamemode If you want to join us, send the application to the [email protected] : We need: • UI Designer - the man should to have good skill into the Photoshop, GIMP, Corel Draw and etc • UI Developer - this man will work with UI Designer to develop any UI elements • GS Developer - the man should to have good skill into the MTA Lua scripting First name: Last name: Gender: Age: Country: City: Vacancy: Ability into this vacancy ( on a scale from 1 to 10 ) Ur payment information ( PayPal, Webmoney, QIWI or plastic card ) to get payday Best wishes, Paulo Minase and HQ Staff of Minase Studio Inc
  16. Hello guys, I have a problem. When I create a house, it is entered into the database is not correct, the icon appears with a standard information that I entered when creating, I can open different windows, but when I restart the script, the house is lost, just when I try to buy it, debugstring: attempt to concatenate local 'value' (a nil value) local 'value' is the same like house ID then when i've closed house window and opened it again debugstring: attempt to concatenate local 'owner' ( a nil value ) local owner in the client side, it's field with owner's name into the house window... Function with local 'value' Database: CreateHouse function: Buy function: Function to get houses from db after restart:
  17. lol i have learning functions but easy to forget it without practic
  18. Yes, ofc i thought about some graphic effects + need to fix some bugs which i have detected idk i have made remove handler for edit boxes but when i'm pressed to the empty place where was edit box and buttons debug string: INFO: Pressed button, INFO: Pressed editbox i think to make animation to hide login behind the screen
  19. i have a problem with sqlite database just i want to create special database for ACL groups and i saw function like this ( but my shit isn't work ) executeSQLQuery do not created table into the db and i think this table has been created in internal.db becouze i saw some the same tables there sorry for bad english function groupdb() groupdb = dbConnect("sqlite", "group.db") if (groupdb) then executeSQLQuery("CREATE TABLE IF NOT EXIST group ( name TEXT, permission TEXT, accounts TEXT )") outputDebugString("You have seccessfully connected to the group.db") else outputDebugString("You have not connected to the group.db") end end addEventHandler("onResourceStart", getRootElement(), groupdb)
  20. thanks but need to finish something in Staff box and update this will be 1.1 version and i think i will post it in community
  21. • Animated menu ( boxes ) • Username/Password saver • Blocker for unallowed signs like $%^@&$^@$%@^$ in the register • Staff box • Update box is not finished, but i think panel seems so nice to be posted
×
×
  • Create New...