FernandoMTA Posted December 3, 2021 Author Share Posted December 3, 2021 (edited) 11 hours ago, SpoonTheMan said: Dang, it's been a long time since I've been active on MTA but with all the amazing breakthroughs that have been happening these last few years I'm starting to think I just might come back soon! I have 3 questions regarding your tool. 1: does it support weapons? 2: can vehicle handling (and possibly weapon stats/effects) be applied independently to added models without changing the handling/stats of the existing content? 3: can added models be added into the F1 menu to be made easy to spawn like the existing content or do you have to enter commands to access added content as a player? Hello! Yes, MTA has come a long way! Let me answer your questions 1. To add new weapons you need a workaround script because MTA currently has no way to do like `addWeapon(object ID, ...)` to assign an object some weapon properties and maybe a weapon ID to make it usable. So because of that, the way you can add a weapon is by adding/replacing an object (with this resource for example) and then make a script to equip that object and shoot with it by equipping a certain existing weapon, making it invisible with shader, and attaching the new object to the ped so it appears that you are shooting from a completely new weapon. This is the workaround I know and it works fine I guess. Here's some stuff related to weapons from the wiki: Default weapons list: https://wiki.multitheftauto.com/wiki/Weapons Weapon skill levels https://wiki.multitheftauto.com/wiki/Weapon_skill_levels that can be set with https://wiki.multitheftauto.com/wiki/SetPedStat Weapon properties: https://wiki.multitheftauto.com/wiki/SetWeaponProperty 2. Vehicle handling can be set serverside on new vehicles (it's explained in the documentation :D) and that works fine! 3. Sure, if this ever gets implemented into MTA:SA default resources somehow, we can have custom new vehicle/skins appear in the F1 spawn menu! Possibilities are endless my friend! Edited December 3, 2021 by FernandoMTA 1 Link to comment
SpoonTheMan Posted December 4, 2021 Share Posted December 4, 2021 9 hours ago, FernandoMTA said: Hello! Yes, MTA has come a long way! Let me answer your questions 1. To add new weapons you need a workaround script because MTA currently has no way to do like `addWeapon(object ID, ...)` to assign an object some weapon properties and maybe a weapon ID to make it usable. So because of that, the way you can add a weapon is by adding/replacing an object (with this resource for example) and then make a script to equip that object and shoot with it by equipping a certain existing weapon, making it invisible with shader, and attaching the new object to the ped so it appears that you are shooting from a completely new weapon. This is the workaround I know and it works fine I guess. Here's some stuff related to weapons from the wiki: Default weapons list: https://wiki.multitheftauto.com/wiki/Weapons Weapon skill levels https://wiki.multitheftauto.com/wiki/Weapon_skill_levels that can be set with https://wiki.multitheftauto.com/wiki/SetPedStat Weapon properties: https://wiki.multitheftauto.com/wiki/SetWeaponProperty 2. Vehicle handling can be set serverside on new vehicles (it's explained in the documentation :D) and that works fine! 3. Sure, if this ever gets implemented into MTA:SA default resources somehow, we can have custom new vehicle/skins appear in the F1 spawn menu! Possibilities are endless my friend! Excellent Answers! Thank you sir! 1 Link to comment
FernandoMTA Posted December 29, 2021 Author Share Posted December 29, 2021 (edited) An update will be released soon! I'm waiting on MTA to update as a few important bugfixes were pushed. (Pull 2474, Pull 2486) Thank you @TheNormalnij I'll also be improving my other project that uses this newmodels library: https://github.com/Fernando-A-Rocha/mta-samp-maploader and publishing the 1st stable release. PS. I've received multiple messages of people wanting to implement this in the OwlGaming Gamemode. I'll see if I can improve the tutorial present in the README.md on the GitHub repo. Edited December 29, 2021 by FernandoMTA 1 Link to comment
FernandoMTA Posted January 25, 2022 Author Share Posted January 25, 2022 (edited) As promised the new update has been published! https://github.com/Fernando-A-Rocha/mta-add-models/releases/tag/v1.6.9 Your server needs to be updated to 1.5.9-9.21125.0 Enjoy and let me know if you'd like to see anything changed or new features. Edited January 25, 2022 by FernandoMTA 1 Link to comment
FernandoMTA Posted March 10, 2022 Author Share Posted March 10, 2022 (edited) NEW RELEASE v.1.7.0: Backwards compatible (almost) Changes: Altered the way you're meant to use spawnPlayer: corrected the example in README which was wrong Added a fix for skin not loading after you re-spawn the player: it now refreshes (#12) Vehicle upgrades are now saved in the server for syncing to all clients. Previously vehicles would lose upgrades every time the model was changed clientside. (#13) Added ignoreTXD, ignoreDFF and ignoreCOL variables to use in mod_list and exported functions for loading models which don't need DFF/TXD(/COL for objects) (suggested by Gaimo#0152) For any support with the newmodels library you can contact me. Details in the README.md Enjoy! Send me screens of newmodels in action in your servers!! Edited March 10, 2022 by FernandoMTA Link to comment
FernandoMTA Posted April 15, 2022 Author Share Posted April 15, 2022 v.1.8.0 is out now! Supports NandoCrypt mod decryption. Link to comment
cocowen Posted May 16, 2022 Share Posted May 16, 2022 i notice this use setelementdata , just want to ask if i have so many custom model do this cause so many lag using this lib Link to comment
FernandoMTA Posted May 16, 2022 Author Share Posted May 16, 2022 46 minutes ago, cocowen said: i notice this use setelementdata , just want to ask if i have so many custom model do this cause so many lag using this lib Hello, this server is currently massively using Newmodels: https://forum.multitheftauto.com/topic/133992-english-wip-6-monthz-in-zombie-apocalypse-roleplay/ They haven't experienced any lag using this lib, you can check it out for yourself Also I have did a lot of testing and it doesn't affect. The element data is set on the vehicle/object/ped you want to have a custom model. Then the client listens to that elemtn data change, this is not performance heavy. You should have no problems Link to comment
cocowen Posted May 16, 2022 Share Posted May 16, 2022 19 minutes ago, FernandoMTA said: Hello, this server is currently massively using Newmodels: https://forum.multitheftauto.com/topic/133992-english-wip-6-monthz-in-zombie-apocalypse-roleplay/ They haven't experienced any lag using this lib, you can check it out for yourself Also I have did a lot of testing and it doesn't affect. The element data is set on the vehicle/object/ped you want to have a custom model. Then the client listens to that elemtn data change, this is not performance heavy. You should have no problems thank u , i am working on a complex server too , so i am very carefull about this performance and glad to try this 1 Link to comment
FernandoMTA Posted January 11, 2023 Author Share Posted January 11, 2023 NEW MAJOR RELEASE: v2.0.0 Click the link above to see the Changelog on the Github Release page. Please update your newmodels & sampobj_reloaded resources to the latest version. You will greatly benefit from the changes. Enjoy! 1 Link to comment
TMTMTL Posted January 11, 2023 Share Posted January 11, 2023 What a massive update Well done brother! - TM 1 Link to comment
FernandoMTA Posted January 12, 2023 Author Share Posted January 12, 2023 Small 2.0.1 update posted with some QoL improvements & a fix for when you try to load hundreds of mods at once. Also uploaded the resource to community.mtasa.com. Link to comment
FernandoMTA Posted January 14, 2023 Author Share Posted January 14, 2023 New 2.0.2 update: replaced couroutines code with use of Asyncio library + fixed removeExternalMod function + newmodels-example fixes. Full changelog on GitHub. Update recommended. Link to comment
FernandoMTA Posted January 14, 2023 Author Share Posted January 14, 2023 (edited) Ever dreamed of mapping with mods in MTA? It's now possible thanks to newmodels. All information about the project here (download). Edited January 30, 2023 by Vinyard updated link per OP's request Link to comment
FernandoMTA Posted January 14, 2023 Author Share Posted January 14, 2023 New v2.0.3 update. The functions changed in this update were unfortunately broken in the previous version. Please update. Link to comment
FernandoMTA Posted January 16, 2023 Author Share Posted January 16, 2023 Released v2.0.4 update. New feature: custom pickup support! createPickup + setElementData. It uses setPickupType to change the pickup model clientside. Thank you @httpRick for the idea. Link to comment
FernandoMTA Posted January 23, 2023 Author Share Posted January 23, 2023 (edited) New v2.1.0 update! The previous 2.0.4 version remains semi-stable, but it is highly recommended that you update your newmodels resource to this version, as well as make use of the new resource added, it simplifies a lot of things. See the full changelog on GitHub (link above). Thank you @httpRick once again for the help. Edited January 23, 2023 by FernandoMTA Link to comment
FernandoMTA Posted January 30, 2023 Author Share Posted January 30, 2023 (edited) New v.2.2.0 update! This update brings many improvements and two small fixes. Highlights: - added "lodDistance" parameter (there are new test mods that demonstrate it) - modList can now be optional (mod_list.lua can be removed if u dont want mods defined in newmodels - added removeExternalMods(ids_list) exported async function - moved start/stop messages from testing_server.lua to server.lua - fixed mod list checks not cancelling the resource because they were inside an Async function - (edge case) fixed startFreeingMod(...) not doing tonumber(data_id) to compare with id, so people who set id element data string had problems See the full changelog on GitHub! Edited January 30, 2023 by FernandoMTA Link to comment
FernandoMTA Posted January 31, 2023 Author Share Posted January 31, 2023 This page is now the documentation's main README, the developer handbook: https://github.com/Fernando-A-Rocha/mta-add-models/blob/main/.github/docs/MAIN.md From there you can find other pages for Lua Examples, Example Resources/Scripts, New-Models in Map Editor, newmodels & newmodels-engine Functions & Events documented. Enjoy! Link to comment
FernandoMTA Posted February 6, 2023 Author Share Posted February 6, 2023 Update v3.0.0 just got released. It was tested and is considered an important & major release. If you are using previous versions of newmodels in your server, it is highly recommended that you read the full changelog and instructions on how to update your custom scripts and benefit from the improvements. Optimization has been always been a concern throughout the project, and some mistakes were made. I can now say that it has been improved. You can compare various newmodels version using the MTA performance browser (/ipb). newmodels has been in development since November 2021. It's now more than a year old! Thank you for all the support, and let's keep making it great! 1 Link to comment
FernandoMTA Posted February 6, 2023 Author Share Posted February 6, 2023 Sorry for another release posted shortly after the previous: https://github.com/Fernando-A-Rocha/mta-add-models/releases/tag/v3.1.0 @httpRick suggested these non-breaking improvements and I couldn't resist Link to comment
itsHasaN Posted March 26, 2023 Share Posted March 26, 2023 hi, i have a problem with re-setting element model to the base model, for example i set a my skin to 20001, its base model id is 1, when i try to re-set the element model to 1 it will not happen, tried with players skin and vehicles. with skins it will work if you change it to something other than the base model but with vehicles its diffrent, you cant use setElementModel to change vehicle model to anything, it will remain the moded model but the handling will get buggy, and after a little bit of time (after the moded model get freed because its no longer needed) it will change, yet to the base model, not the model i asked for. but the server thinks its alright, the vehicle name when i enter is the one i changed to and when i reconnect the model will be the model i requested Link to comment
dalexoxo Posted April 19, 2023 Share Posted April 19, 2023 how i can spawn a custom vehicle with a external script?^^ Link to comment
dalexoxo Posted May 17, 2023 Share Posted May 17, 2023 how do i load the map without having the editor open? i mean how do i start the map external with custom objects? 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