-
Posts
2,973 -
Joined
-
Last visited
-
Days Won
3
Everything posted by 50p
-
These are types of variables. I meant that if parameter on wiki says that there should be a "string" (representing name of account) there should be string. So I wrote that: string (param of the function) must be string ("blah blah") string (param of the function) cannot be userdata (source, which represents player is a userdata type of variable) EDIT: I have just tested this short script and it seems there must be an error in getAccount function... I get the same message as you have shown above on the screenshot of console.
-
mabako meant to use 'getAccount( source )' instead of 'getAccount( getClientName( source ) )' But params shown on wiki says: string is string string is not userdata So username should be a string not an element.
-
I don't know how R* made these icons but I tried and couldn't make it, look: ROFL! Anyway, mabako, how have you tried to give Jetpack? Using function givePlayerJetPack?
-
It would be really useful if we had such event, since if we want to display an image onPlayerJoin player has to download the resource (images) and then we are able to display the images on the client-side. We can use timer, but if resource is "heavy" (eg. 2MB) it'll take a bit to download it. We don't know players' net connection, therefore we cannot make a timer which depend on players' net speed. Now players have download the resource and reconnect to be able to see the images. I wanted to make a choosing team window with images but new players' will not see the window, since they are new and they have to download required files. With such event we could know when we can call specific functions. It doesn't just link with images, but also with .dff and .txd files. We don't know when to start replacing vehicles because we don't know whether player has downloaded the resources. I hope you'll add it to your "TO DO" list.
-
There needs to be a timer. I guess there must be only key binding. Timer is needed to update players' screen.
-
Use getAccount function. local account = getAccount( getClientName(source) ) if account then -- if account exists then send player a message to login else -- otherwise tell the user to register to play end
-
I'm Polish and it's hard for me too, but I try because I know what I want from life, LOL. I've learnt other programming languages and I know that if you know at least one, you'll learn others easier.
-
Then here is your friendly manual.
-
101 loaded. Make sure the script is not only loaded, but also running.
-
Why don't you try and see?
-
In stealth, you can move camera when you join the game, choose your weapons/gadgets and the round is running at the moment you want to play. Then just press R and you can look around.
-
I guess nobody. Similarly with vehicles, but I've had vehicles textured.
-
http://development.mtasa.com/index.php? ... lientEvent You can see there is a param "theElement", this is where you can specify on which client you want to trigger the event. Use wiki first, then ask.
-
To call a function from server in client script use: triggerServerEvent To call a function from client in server script use: triggerClientEvent But first you'll have to addEvent in a script which than may be called. Check these functions: http://development.mtasa.com/index.php? ... _functions
-
Because the orb is not a 2d image.
-
Try this: function replaceTheObjs() dff = engineLoadDFF( "map/box.dff", 2918 ) engineReplaceModel( dff, 2918 ) txd = engineLoadTXD( "map/box.txd", 2918 ) engineImportTXD( txd, 2918 ) createObject( 2918, 0,0,3 ) end addEventHandler( "onClientResourceStart", getResourceRootElement( getThisResource() ), replaceTheObjs ) It is client-sided script. It should replace the object 2918 and load its texture, then create the object at given co-ords (when resource starts). You can do it in onPlayerConnect, but don't create object then, since you'd create lots of objects at the same place, causing slowing down all connected PCs.
-
lol this is not a model from me its from the Picture of the Day on MTASA.com pwned, forgot about them! There ware so many screenshots that I can't remember them all, lol. 50p can you pleas tell me waht script you used to load this models? I used my own simple script. Placed it in a function and added to event: onClientResourceStart (obviously it is client-sided script) dff = engineLoadDFF( "map/box.dff", 2918 ) engineReplaceModel( dff, 2918 ) txd = engineLoadTXD( "map/box.txd", 2918 ) engineImportTXD( txd, 2918 ) Then just used command to create object '2918' (I can't remember which resource has that command). Col file is not required in my objects, because I attach it to the object itself.
-
Put up this script somewhere! upload plz ------------------------------ I do not speak in English! He's asking questions not showing a script. 1. Can't remember this one. 2. As far as I know; no, it is not possible to add new object to game with its own ID. In SP it was quite possible. 3. If you show us your screenshots I guess you have them. BTW, I can't get texture to be loaded, don't know what may be wrong. Here are my screenshot and rendered object how it should look like: http://img88.imageshack.us/img88/1824/m ... 001xb4.png http://img182.imageshack.us/img182/5512/renderfc3.png
-
Your directions made no sence. and then your all like "your almost there" I DONT KNOW HOW TO GET IT TO WORK, AND NONE OF THE WIKI MAKES ANY SENCE. . If my directions have no sense to you then there is no way we can help you yet. No body has got time now to help you if they want to help themselves. MTA is fresh yet and everyone is testing functions, updating wiki, and stuff. If wiki doesn't help you to learn scripting for MTA then you'll always post requests, you'll never learn LUA. I remember the time I first started learning programming. I didn't even know that software (all the applications we use) are written in some kind of code! I didn't even know that there are 10s of programming/scripting languages. I had to spend days just to write a simple calculator in C++. Then I started learning PAWN, it was nightmare to get answers from people like Y_Less who's just giving hints. I didn't understand what is meant by: "put this code in OnPlayerConnect"! It took me couple of months to learn PAWN. Once I have learnt something it is easier to learn other languages including LUA. I have had many situations that I wanted to throw my keyboard through the window! Think about my start and compare it with yours.
-
If you ask for ready code and get it once, you'll come back ask for code again and again and again... until we make it for you. When MTA was released (dp1) I started reading wiki. I knew what you know now, and now I know a bit more and understand what you may feel like now. I don't ask much for help because my way of getting used to programming is learning myself by reading a lot. But if you ask for ready-working-code then you should try reading a lot, and then ask some lil' questions about "what is wrong with my code?", "why isn't it working?". And again don't ask for lots of code. Don't get offended because everybody must have their first time. Do you think scientist was scientist from the day he was born? No, he must learn before he becomes one. Also, MTA was released 2 weeks ago, and do you all expect everyone know everything just to help you? We must first learn to help others (that's what I am doing). I gave you exact directions to functions you'll be in need of.
-
http://y50p.50g.com/archives/server_01192008_1600.zip
-
You're almost there. Just learn a bit more. KeyBind should call a function which would create the image on all of the players' screen.