Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 17/11/21 in all areas

  1. mta-add-models is a library/framework resource that I made: Its purpose is allowing you to add new peds(skins)/objects/vehicles to your server. All the new added models will be automatically synced with all players. Supports encrypted mod files using the NandoCrypt system. As of v2.0.0, files with attribute download="false" in meta.xml are supported, and newmodels will handle downloading them! The way to achieve this is by following the tutorial included in the project's documentation (see GitHub link below) The resource comes with test commands for you to experiment with the mods provided and see what's going on under the hood. You're meant to make your own implementations to use newmodels in your server's complex systems. GitHub Repo (Download): https://github.com/Fernando-A-Rocha/mta-add-models#readme (Documentation here) (NEW) Custom Map Editor Community Page (Alternative Download): https://community.multitheftauto.com/index.php?p=resources&s=details&id=18598 For support/questions please access my main thread: https://forum.multitheftauto.com/topic/139644-rel-nandos-resources/ I hope you enjoy!
    3 points
  2. I like the idea of your resource! It acts as a scripting backend, hence the suffix "(library)", which allocates new real model IDs for your own virtual set of model IDs. There appears to be a requirement to a fixed set of models into the resource so that it can sync them to players. Found issues in version 1.1.0 if there are two peds synced for the player and both have the same custom model assigned to them, then if one of them streams out your syncer attempts to release the custom model for both of the ped elements, especially the one already streamed in. While the documentation of engineFreeModel does not mention what happens in this case, I assume that the request fails. This scenario is a potential model ID leak (the client will run out of available real model IDs at some point). Even worse: the client could run out of RAM very quickly. Here are my suggestions add a custom model cache based on usage frequency, API hinting (setCustomModelAlwaysLoaded) or database flag so that MTA does not have to perform the expensive disk loading of model data as frequently (improves FPS) add a way to register custom models from other storage resources. This way custom models could potentially be downloaded from the server on-demand by a second resource and - after finishing the download - be registered as custom model inside of your own resource. Could be really fun! add statistics API about the number of custom models loaded, their usage details (frequency, number of elements with the model, etc) and the general performance of the resource. You could even add a debug dashboard using some hidden key combination (very important to build user-trust into your resource workings) One issue and suggestions · Issue #1 · Fernando-A-Rocha/mta-add-models (github.com) Nice work so far! Keep it up.
    2 points
  3. I really like that you have quickly added a lot of debug feedback to your script! I am looking at things such as the drawAllocatedTable function and I am impressed with the progress of your resource. Some suggestions · Issue #3 · Fernando-A-Rocha/mta-add-models (github.com) Not checking the element-data key during onClientElementDataChange · Issue #2 · Fernando-A-Rocha/mta-add-models (github.com) Element models not released by destroyElement (issue?) · Issue #4 · Fernando-A-Rocha/mta-add-models (github.com)
    1 point
  4. Wow... When I saw that MTA allows creating new model IDs but it was only client-side, I though, "oh, that's nice, we're close to it, but it's not time for it yet". It never occurred to me that we can just create elements with built-in models and then call setElementModel on the client. Great job!
    1 point
  5. O simpla functie care te ajuta sa salvezi coordonatele tale intr-un fisier .txt: function pos(thePlayer, command) local x, y, z = getElementPosition(thePlayer) if not fileExists("posave.txt") then local pathFile = fileCreate("posave.txt") fileClose(pathFile) elseif fileExists("posave.txt") then local openFile = fileOpen("posave.txt") local sizeFile = fileGetSize(openFile) local dataFile = fileRead(openFile, sizeFile) fileWrite(openFile, "\n"..x..", "..y..", "..z.."") outputChatBox("Saved: "..x..", "..y..", "..z.."", root, 255, 255, 255, true) fileClose(openFile) end end addCommandHandler("gpos", pos) O functie care iti zice daca se aude sunetul sau nu: Poate fi gasita si aici: https://wiki.multitheftauto.com/wiki/IsSoundPlaying function isSoundPlaying(theSound) return (getSoundPosition(theSound)) end O functie care iti zice daca elementul este in aer sau nu: Poate fi gasita si aici: https://wiki.multitheftauto.com/wiki/IsElementInAir --// Varianta 1 (Valoarea default este 10) function isElementInAir(element) local x, y, z = getElementPosition(element) if element and isElement(element) then if z >= 10 then return z end end end --// Varianta 2 (Pui tu valoare la Z) function isElementInAir(element, ZPos) local x, y, z = getElementPosition(element) if element and isElement(element) then if z >= tonumber(ZPos) then return z end end end O functie care creeaza un dreptunghi 3D deasupra jucatorului: Poate fi gasita si aici: https://wiki.multitheftauto.com/wiki/DxDrawRectangleOnPlayer function dxDrawRectangleOnPlayer(x, y, width, height, color) local players = getElementsByType("player", root, true) if players then local x, y, z = getElementPosition(localPlayer) for _, v in ipairs(players) do if v and isElement(v) then local px, py, pz = getElementPosition(v) if getDistanceBetweenPoints3D(x, y, z, px, py, pz) <= 20 then local sx, sy = getScreenFromWorldPosition(px, py, pz + 1.3) if sx and sy then dxDrawRectangle(sx + x, sy + y/1.6, width, height, color, false) end end end end end end
    1 point
  6. I'm using on my server abd it'd working all good. ass. Estrela
    1 point
  7. Seems like a good idea, well done.. I will try it later good luck
    1 point
  8. In addition to the existing "Report community resources here" topic, this thread will list up the community guidelines outlining how the community should be used. Whilst these regulations cover a few popular situations, it is not to a strict rulebook—that is to say, the overarching rule is for you to be a good standing community member. Here are some criteria you should follow when sharing resources: Do not upload simple resources. These are: Vehicle/skin/weapon mods that primarily consist of DFF/TXD replacements. There are other places to share San Andreas mods. There are some exceptions, rare type of mods that, as a resource, do not work off the bat with MTA from GTA sources are allowed, such as tyre/wheel/weapon mods (aslong it's a pack), map and building, interior mods (Example: a map that consists of custom GTA objects or world parts) Resources solely based on code examples from the wiki "Useless resources": extremely simple scripts, especially one-liners Compiled resources based on a too small codebase (not worth to compile). Do not upload resources that do not do as advertised (this includes resources that are horribly broken) You are not allowed to upload resources that act solely as a publicity mirror (such as uploads with links to external websites to download the actual resource) You should not try to monetize your resources by using pay links (such as adf.ly). This can get you banned. Do not upload resources containing code you do not have the rights to (i.e, stolen code). Read the notes below for more information. The comments section is not a place to argue about resource stealing. Instead you should report said resources. Improving or fixing existing resources Although uploaded resources are made, by their author, for public download; the general rule is that you do not copy existing resources that you do not have the rights to. Then again, it may benefit the entire community if an old and abandoned resource is given new updates, which for that reason we, staff/moderators, may regularly do for some popular resources (as a form of Q&A, often for the reason of containing game-breaking bugs or being of low quality). If you want to help out like this yourself, see the question ''What do I do if I find a resource that has been abandoned?'' What do I do if I have a fix for a resource with a bug? Making small adjustments to resources and reuploading them as your own is not allowed. You need to contact the resource author so they can apply the fix and update the resource, or eventually grant you permission to do so. In some circumstances we the moderating team can patch resources if the author does not seem receptive to messages, where problems potentially affect large amounts of players/servers, or a (much downloaded) resource is of a quality detrimental to community. What do I do if I find a resource that has been abandoned? Please visit this thread if you would like to adopt a resource. If you find "fixed" resources that were not uploaded by the original author and to which the below exceptions details do not apply, then please report them (in this case, please only report newly uploaded resources after this policy's introduction date, so that old resources by inactive members are not removed). Exceptions: Re-uploading resources customized to target another gamemode/main purpose and/or using the original resource to base your edition off It can sometimes be allowed to upload modified resources if they change targetting overwhelmingly. If your re-upload is of a version (rather ''edition'') that cannot be unified with the original resource, because it has a different purpose or the changes made are converting it to a different target gamemode (for example, you use an existing adminpanel and change the buttons/functionality into a DayZ-gamemode panel). While you are not strictly required (by us) to see if the original author is inactive or will reply to you/permit it (unless included licenses say so), you will have to remove the material incase they explicitly request you to do so later on, as your resource will still be partially based off their work. Also if any original license forbids it or sets terms, you'll have to respect it and/or not do so. This exception is only valid for reasons such as the last mentioned, if due to that being the case both resources must have a different community listing. You are however required to mention and link to the original resource, and credit its authors in order to fall under this exception. Translated resources are also eligible if the same circumstances have been met. Other questions? What happens if I break the rules? (by discretion of the moderator) Depending on the situation, your content may be removed, or suspended. In addition, you may receive (temporary, in many cases) a community and/or forum ban. The regular rules about ban evading apply. All of this seems very obvious, yes, but extremely abusive behaviour on the community may result in a global ban from MTA. We are actively monitoring the community, and we apply common sense to all cases. As mentioned earlier, the absence of a rule does not mean the behaviour is allowed. How can I help? Make sure your email address on the forum and community are up to date, and if possible, establish a relationship between both your community profile and your forum profile. We will usually explain the reason for your resource being suspended in the resource log or comment section, and/or possibly over forum PM if your username is clear or we manage to link you. This helps make it easier to get in touch, and will prevent the situation where you simply re-upload the resource because you notice your resource has disappeared. We also encourage anyone who notices a resource in violation of these guidelines to click the newly added "Report" button below the description of all resources. The button will direct you to the below topic; If you want your own resource(s) deleted, or have something changed or corrected to it, you can make a post ("report" your own uploads) in the same fashion as written above, link your upload and describe your request on what needs to be done. Please note that all removal requests are subject to staff discretion, for example it's unlikely that we will delete popular resources (high download count, thus valuable to the broader community) even if the original author asks us to. Unless your license (if any, on the version you request removed) specifically states you got this power, you made a conscious decision to add your materials to the public domain by sharing it initially, and it would be near egoistic to take it away from others who are clearly finding it useful to this day. Note: Most of these regulations do also apply to Resources section release topics that may use alternate download mirrors other than community.multitheftauto.com (but will only be applied at moderator/staff discretion as not all of them can apply for those). As we do not control external hosting mirrors, the only thing we can do to enforce our regulations and demands is taking actions against the Resources section release topic and forbid placement of it, or subject it to additional requirements or changes. Additional regulations for the "Resources" subforum: - Topic title should be prefixed with either [REL], [DEMO] / [SHOW] or [SELL]. If you use the release prefix, the resource(s) that you're posting about should be publicly downloadable. If you use the demonstration prefix, then it's allowed to show off your private scripts or WIP's without any intention to publish it (or with the intention to publish it later). - If you upload resources posted in the 'Resources' section to external mirrors rather than the community page, then they must be uncompiled. We won't allow such content (compiled .luac) to be self-hosted out of security considerations. The community provides us with tools to deter malicious resources, if you come across a compiled DL on the forums then please be aware that we cannot protect your server from harm if you did use it, we kindly request you to report the topic in question instead. - Selling resources and gamemodes is only allowed in the "Resources" subforum and not in any other forum section, or on Discord, specifically in the #showroom channel (single post allowed). You're encouraged to sell only particular resources or a limited list of resources, bundled in a single topic. Bumping such topics (for the sole reason of bumping, like 'bump') is not allowed, nor is having alot of sale topics simultaneously: Moderators may judge on a case by case basis that you have too much selling activity or too much sale topics at the same time; we'd like to prevent commercial activities in this section from drowning out releases or show-offs. Anyone engaging in selling activities is doing so at their own risk, always take caution in dealing with a seller or buyer, and remember that if it seems too good to be true, it usually is. We recommend to review a member's forum reputation, activity & standing before making decisions. False deals can be either a scam or a person selling something not egilible for sale (not their work, stolen, leaked or public resources and code, etc) or unreasonable deals (qualitatively low value work for a too high price, misrepresentation of features or quality, etc), because of this we advise that if you doubt or aren't an experienced scripter, you call for the help of someone you know can tell if it's a reasonable deal and the product being sold looks good or not. We advise that you always press the seller for full source code and not compiled or otherwise protected, because you should ideally be buying the full rights to a work when you purchase it. While we cannot guarantee the safety of trading (for which reason we advise you to use common sense and precautions), we will do our best to intervene if a situation related to a scammer looking to make victims, having made victims, or of someone selling unreasonable products is brought forward to us. We kindly request you to submit a topic, post, or PM report in such situations or if you're concerned about anything. By reporting situations you allow us to prevent (scamming) incidents, eventually assist to resolve trading conflicts, or take action against scammers after the fact. Setting out to scam others is rewarded with a permanent ban, eventually a ban from all MTA services. By engaging in sale or trading activity on the MTA forums or Discord, you inherently agree to all of these terms and the fact that our decisions, arbitration, instructions and demands are final, to be judged on a case-by-case basis if we get involved. Legal disclaimer: (open spoiler by clicking ''Reveal hidden contents'')
    1 point
  9. I have seen quite a few releases here on the forum that are not on the community, MTA's resource download center. On https://www.mtasa.com go to "maps and modes" link to access the community center. You can upload resources here: https://community.multitheftauto.com/index.php?p=resources&s=upload
    1 point
×
×
  • Create New...