donut Posted August 10, 2009 Share Posted August 10, 2009 Hello, I have a question I wanted to do this when on my server which is connected to a window opens with some text, and with my own logo. So maybe someone knows how that does? Link to comment
DutchCaffeine Posted August 10, 2009 Share Posted August 10, 2009 That is eisier then replacing a vehicle model. First take a look at: development.mtasa.com (in the menu: wiki) Allright, we are going to create a window with the width of 500 and the height of 300 (nice window ) local welcomeWnd = nil; function createWelcomeWindow() -- Get the client screen resolution. local scr = {guiGetScreenSize() }; -- Create the w and h variables (width, height) local w, h = 500, 300; -- Create the x and y variables, and we are going to center the window right here. Just watch and see. local x, y = (scr[1]/2)-(w/2), (scr[2]/2)-(h/2); -- Now we are going to create the window. (it will be centered in all resolutions.) welcomeWnd = guiCreateWindow(x, y, w, h, "The title", false); guiSetVisible(welcomeWnd, false); end -- Now add the event onClientResourceStart (when the client has downloaded all the files) addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), function() createWelcomeWindow(); guiShowCursor(true) guiSetVisible(welcomeWnd, true); end); That was easy Link to comment
donut Posted August 10, 2009 Author Share Posted August 10, 2009 THX. Now have another question (sorry so many question because I know with the code of MTA did not'm still from beginner ^ ^) I use always votemode and so do I have the code now in every mode, the insert or even easier? Link to comment
50p Posted August 10, 2009 Share Posted August 10, 2009 I don't know if that's what you want https://community.multitheftauto.com/index.php?p= ... ails&id=38 Link to comment
donut Posted August 10, 2009 Author Share Posted August 10, 2009 thx thx thx Hm where I need to do? Habs in hingetan resources comes at the beginning but nothing: ( 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