Jump to content

DiSaMe

Helpers
  • Posts

    1,449
  • Joined

  • Last visited

  • Days Won

    32

Everything posted by DiSaMe

  1. Use setElementDimension client-side. For example, you can get the dimension of the local player in onClientPreRender event, check if it has changed since the last frame and if so, use setElementDimension to change the dimension of the marker to the player's dimension. Client-side dimension changes are not synced automatically, so every player can see the same marker in their own dimension.
  2. You can replace the models during the whole gameplay process. For example, if you go to one place, the model ID has some model, then if you go to another place, another model is put into the same ID slot. If you make it like this, you may have multiple different models with the same ID as long as you make sure that these models are not both visible for the player at the same time.
  3. If that doesn't make it clear for you, maybe I should also add these: setPedRotation https://wiki.multitheftauto.com/wiki/FindRotation
  4. If that means reinventing, then I spend a lot of time reinventing. There is one thing which can only exist as long as it's reinvented: originality.
  5. toggleControl setControlState
  6. Because localplayer is probably undefined, you probably meant localPlayer.
  7. I haven't made a proper obstacle checking yet. The cars only stop if there's an obstacle in the middle. Otherwise they keep driving. As for stealing the cars, you can't just pull the peds out of them (MTA limitation), but you can kill the peds, they will fall out and you will be able to take the cars.
  8. So, you have downloaded what you need (except the ByteData, you don't need to download it, it's already included in the traffic resource). Now you have to extract these archives, override the contents of npchlc_traffic (from npchlc_traffic_0.1 archive) with the contents of paths_san_andreas_1.0 archive. Move the folders npc_hlc, server_coldata, npchlc_traffic and optionally npchlc_traffic_denctrl to the server resources folder, then start npchlc_traffic.
  9. This problem was solved a few days ago: http://bugs.multitheftauto.com/view.php?id=7478
  10. Did you install the paths into the traffic resource? It says how to do this in the documentation. Put the contents of the path archive into the traffic resource in such way that it would overwrite the maplist.xml. I made the script and the paths separate, so that users would not need to redownload the paths in case I update the script.
  11. I have a 32-bit Ubuntu system and I also have libmysqlclient.so.16, but MTA needs libmysqlclient.so.15, so I googled it, downloaded it and then put it into /usr/lib and now MySQL functions work fine.
  12. How did you edit the model? The world object cannot just move when replacing the model. Maybe you edited it in such way that its all vertices are moved, resulting in movement of its geometric center while the object position remains the same?
  13. From the image which you posted (http://i.imgur.com/r39PlhN.jpg) I can see it does because resolution of the object texture is very low in that image. If you see the same low LOD model when you approach the object, that means the high-detail object has been removed successfully and you just need to do the same with lod LOD object. But if the main object is still present, I have no idea what the problem could be.
  14. Did you only remove the main object or its low LOD object as well?
  15. Well, then you could try another way. Remove the original object with the function: removeWorldModel And then just create the object in the same place.
  16. When you are far from the object, it's invisible. Its low LOD counterpart is shown instead. When you approach the object, it becomes visible. As long as the object which you created is in the exact same position as the world object and alpha/collisions are set to 0/false, there should be no problems - the only effect should be model replacement for the world object. I can't think of anything else to change.
  17. DiSaMe

    Question

    Exactly. If limit for the strings sent to client is 65535 characters and the string couldn't be sent, that means it is longer than 65535 characters. And if you want to send that string without changing minimum client version, you have to workaround this. You could try splitting the string into multiple shorter strings using string.sub function and sending them as separate arguments. If that doesn't help, you could send multiple strings by triggering the event multiple times and joining the strings client-side.
  18. DiSaMe

    Question

    There is no limit. You can put as many values as your computer can store.
  19. Everything is fine with your primary script. Model replacement only has effect when at least one MTA element with that model is streamed in. Probably the simplest way to do what you want would be creating an object with the same model in the same place where the world model is and making it invisible and non-solid using these functions: createObject setElementAlpha setElementCollisionsEnabled When you do this, the object itself won't interact with the world, but because it is streamed in when you approach it, it will cause the model replacement to be visible and in result, the world object will change.
  20. Does the XML file exist client-side? It must be either created in a client-side script or downloaded from the server by putting into meta.xml to exist on the client.
×
×
  • Create New...