Message from the CDT to all NS2 Modders about 267

GhoulofGSG9GhoulofGSG9 Join Date: 2013-03-31 Member: 184566Members, Super Administrators, Forum Admins, Forum Moderators, NS2 Developer, NS2 Playtester, Squad Five Blue, Squad Five Silver, Reinforced - Supporter, WC 2013 - Supporter, Pistachionauts
edited July 2014 in Modding
Greetings fellow modder buddies,

we all know the pain of a new build coming out that suddenly breaks your working mod.

To avoid that this will happen with 267 i tested the most popular mods at current 267 RC.

Here is the detailed list:
https://docs.google.com/spreadsheets/d/1ZtiEudFw4E_opGMBvKvXLqx1KxV1hWY3cCHR8h86Whc/edit#gid=0

Generally there are three changes you have to be aware of as modder:

1. The Whip class got basically rewritten. So if you modified whips in any way please look at the new whip class and see how you have to redefine your mod functions
2. Draw Games: Draw Games are now a valid option in vanilla and the chance of them happening has been slightly increased. So make sure your mod can deal with that at NS2Gamerules:Engame( winningTeam ) winningTeam might be nil ( = Draw Game )
3. Font Precaching (optimal): With 267 we added Font Precaching. To use the precached fonts please use the given entry out of the Fonts table of the GUiAssets class which will get added with 267.

Fonts table from GUIAssets.lua:
Fonts.kAgencyFB_Huge = PrecacheAsset("fonts/AgencyFB_huge.fnt")
Fonts.kAgencyFB_Large_Bold = PrecacheAsset("fonts/AgencyFB_large_bold.fnt")
Fonts.kAgencyFB_Large = PrecacheAsset("fonts/AgencyFB_large.fnt")
Fonts.kAgencyFB_Medium = PrecacheAsset("fonts/AgencyFB_medium.fnt")
Fonts.kAgencyFB_Small = PrecacheAsset("fonts/AgencyFB_small.fnt")
Fonts.kAgencyFB_Smaller_Bordered = PrecacheAsset("fonts/AgencyFB_smaller_bordered.fnt")
Fonts.kAgencyFB_Tiny= PrecacheAsset("fonts/AgencyFB_tiny.fnt")
Fonts.kInsight = PrecacheAsset("fonts/insight.fnt")
Fonts.kArial_15 = PrecacheAsset("fonts/Arial_15.fnt")
Fonts.kArial_17 = PrecacheAsset("fonts/Arial_17.fnt")
Fonts.kKartika_Small = PrecacheAsset("fonts/Kartika_small.fnt")
Fonts.kStamp_Large = PrecacheAsset("fonts/Stamp_large.fnt")
Fonts.kStamp_Medium = PrecacheAsset("fonts/Stamp_medium.fnt")
Fonts.kStamp_Huge = PrecacheAsset("fonts/Stamp_huge.fnt")
Fonts.kMicrogrammaDMedExt_Large = PrecacheAsset("fonts/MicrogrammaDMedExt_large.fnt")
Fonts.kMicrogrammaDMedExt_Medium = PrecacheAsset("fonts/MicrogrammaDMedExt_medium.fnt")
Fonts.kMicrogrammaDMedExt_Medium2 = PrecacheAsset("fonts/MicrogrammaDMedExt_medium2.fnt")
Fonts.kMicrogrammaDMedExt_Small = PrecacheAsset("fonts/MicrogrammaDMedExt_small.fnt")

Also Hotloading will get changed with 267 to be actually useful and not buggy. If you want to know how the new hotloading works please have a look at Hotload.lua in the ns2/lua folder once 267 is out.

In case your mod is missing in the list or you want to know if that one for you critical function got changed feel free to comment.

Please notice that i will only answer coding questions and won’t help you out with a mod which basically only overrides vanilla files as those mods break with each new build.

I will soon publish a guide about modding where i will explain how to avoid that your mod breaks whith each build via using hooks.
Please wait for that ;)

Your CDT

Comments

  • Soul_RiderSoul_Rider Mod Bean Join Date: 2004-06-19 Member: 29388Members, Constellation, Squad Five Blue
    edited July 2014
    Hey @GhoulofGSG9‌. I don't have access to my PC due to my current personal situation. Would you be able to test GorgeCraft for compatibility? It should be OK, but you never know....

    I must say, my mod only overwrites vanilla files, but very rarely breaks on NS2 updates.
  • GhoulofGSG9GhoulofGSG9 Join Date: 2013-03-31 Member: 184566Members, Super Administrators, Forum Admins, Forum Moderators, NS2 Developer, NS2 Playtester, Squad Five Blue, Squad Five Silver, Reinforced - Supporter, WC 2013 - Supporter, Pistachionauts
    edited July 2014
    Soul_Rider wrote: »
    Hey @GhoulofGSG9‌. I don't have access to my PC due to my current personal situation. Would you be able to test GorgeCraft for compatibility? It should be OK, but you never know....

    Gorgecraft overwrites the GUIMainMenu.lua.

    The Mainmenu was changed in 2 aspects:

    1. We redesigned the way how Links are handled to make it easier to add new ones and change the order of them etc.
    2. All strings are now linked to the gamestring text files.

    Those changes cause that no mod which overrides any main menu file without including the old mainmenu.css works without making the main menu unusable.

    Also a little tip for the future how to mod the mainmenu and be able to update it in less than one minute for ever new patch.

    Make a file called GUIMainMenu_Vanilla.lua and copy pastethe vanilla GuiMainmenu.lua content into it.

    Then create your mods GUIMainMenu.lua lokking like this:
    Script.Load("lua/menu/GUIMainMenu_Vanilla.lua")
    
    --do your mod stuff here
    

    By this you only have to copy and paste the vanilla GUIMainMenu.lua into GUIMainMenu_Vanilla.lua to keep your mod updated ;)
  • DaveodethDaveodeth Join Date: 2012-11-21 Member: 172717Members
  • meatmachinemeatmachine South England Join Date: 2013-01-06 Member: 177858Members, NS2 Playtester, NS2 Map Tester, Reinforced - Shadow, WC 2013 - Supporter
    Daveodeth wrote: »
    Build 276?

    With the sheer number of changes/improvements why not skip a few build numbers? :P
  • Soul_RiderSoul_Rider Mod Bean Join Date: 2004-06-19 Member: 29388Members, Constellation, Squad Five Blue
    OK, well, I am unable to fix this as I don't have NS2 on my phone or laptop.. I guess it will have to remain broken until I get sorted out :P
  • GhoulofGSG9GhoulofGSG9 Join Date: 2013-03-31 Member: 184566Members, Super Administrators, Forum Admins, Forum Moderators, NS2 Developer, NS2 Playtester, Squad Five Blue, Squad Five Silver, Reinforced - Supporter, WC 2013 - Supporter, Pistachionauts
    Soul_Rider wrote: »
    OK, well, I am unable to fix this as I don't have NS2 on my phone or laptop.. I guess it will have to remain broken until I get sorted out :P

    I can offer to upload a fixed version to the workshop in your case.
  • Soul_RiderSoul_Rider Mod Bean Join Date: 2004-06-19 Member: 29388Members, Constellation, Squad Five Blue
    Thanks for the offer, but I was just wondering.... If I lock the build to 266 for now, wouldn't that do it? As a temporary fix until I can get back online to do it properly?
  • GhoulofGSG9GhoulofGSG9 Join Date: 2013-03-31 Member: 184566Members, Super Administrators, Forum Admins, Forum Moderators, NS2 Developer, NS2 Playtester, Squad Five Blue, Squad Five Silver, Reinforced - Supporter, WC 2013 - Supporter, Pistachionauts
    edited July 2014
    Soul_Rider wrote: »
    Thanks for the offer, but I was just wondering.... If I lock the build to 266 for now, wouldn't that do it? As a temporary fix until I can get back online to do it properly?

    Actually the build fallback method is not working for the Mainmenu VM. For now i would just delete the lua/menu folder and be fine with it ;)

    I think all ppl get that to play gorgecraft they have to start a local server :D
  • MetaMindMetaMind Join Date: 2012-12-06 Member: 174358Members, Reinforced - Gold
    would be nice if you could test 267 with my mod: Last Resistance(Survivor)
    Also it was mentioned that 267 has mods backwards compatiblity ... is this only functioning when the mod is written with hooks?
  • GhoulofGSG9GhoulofGSG9 Join Date: 2013-03-31 Member: 184566Members, Super Administrators, Forum Admins, Forum Moderators, NS2 Developer, NS2 Playtester, Squad Five Blue, Squad Five Silver, Reinforced - Supporter, WC 2013 - Supporter, Pistachionauts
    edited August 2014
    MetaMind wrote: »
    would be nice if you could test 267 with my mod: Last Resistance(Survivor)
    Also it was mentioned that 267 has mods backwards compatiblity ... is this only functioning when the mod is written with hooks?

    As Last Resistance(Survivor) mainly replaces vanilla files it doesn't work with 267 ;)

    There will be a new configuration field which allows you to mount your mod at a given ns2 version. It will work with all kind of mods. But should be avoided to be used for any non gamemode mod.

    Also new versions of ns2 always include tons of bugfixes which might also affect your mod. So if you don't overload the load order of all vanilla files you should try to use hooks instead of mounting an old build version.

    The option to mount old ns2 build version is mainly meant to be used for mods which are not activly developed anymore.
    Also have in mind that if you use that option mostly no other mod will work with your mod.
  • MetaMindMetaMind Join Date: 2012-12-06 Member: 174358Members, Reinforced - Gold
    Thx for the quick response...
    The thing is that its written with hooks and overwriting vanillas...some changes arent possible though hooks and it was kinda messy... I think I will stick with the version locking feature (super cool btw... this comes in very handy)
    Also when I use version locking do custom maps and skins fall into the "non gamemode mods" category as you mentioned before?
  • GhoulofGSG9GhoulofGSG9 Join Date: 2013-03-31 Member: 184566Members, Super Administrators, Forum Admins, Forum Moderators, NS2 Developer, NS2 Playtester, Squad Five Blue, Squad Five Silver, Reinforced - Supporter, WC 2013 - Supporter, Pistachionauts
    edited August 2014
    MetaMind wrote: »
    Thx for the quick response...
    The thing is that its written with hooks and overwriting vanillas...some changes arent possible though hooks and it was kinda messy... I think I will stick with the version locking feature (super cool btw... this comes in very handy)
    Also when I use version locking do custom maps and skins fall into the "non gamemode mods" category as you mentioned before?

    Skins and Maps will work fine, basically all the build version rollback function does is mounting the complete lua code of the given ns2 build before mounting your mod.

    Saying so any mod which uses functions or relays on stuff that was added after the build version you roll back to will break. Also rolling back means undoing all the performance, balance and bug fixes newer builds add.

    E.g. You will undo most of the hitch fixes of 267 if you roll back to 266 with your mod. Also i can't imagine there is something you can't do with hooks.

    That's one of the best things about lua. You can change anything in the global table after it was defined.
  • MetaMindMetaMind Join Date: 2012-12-06 Member: 174358Members, Reinforced - Gold
    edited August 2014
    will see if 267 have that much of a performance improvement over 266... if so I will fix it to 267 manually...
    Also a bit offtopic: I tried the vanilla bots skulks but they werent attacking at all, to my wonder the Fade bot was moving around but didnt attack either, 2-3 month ago alien bots were able to attack, will this be fixed in vers 267 also?
  • MetaMindMetaMind Join Date: 2012-12-06 Member: 174358Members, Reinforced - Gold
    unable to change version locking inside launchpad --> configure.... its not shown the full window
  • aeroripperaeroripper Join Date: 2005-02-25 Member: 42471NS1 Playtester, Forum Moderators, Constellation
    MetaMind wrote: »
    will see if 267 have that much of a performance improvement over 266... if so I will fix it to 267 manually...
    Also a bit offtopic: I tried the vanilla bots skulks but they werent attacking at all, to my wonder the Fade bot was moving around but didnt attack either, 2-3 month ago alien bots were able to attack, will this be fixed in vers 267 also?

    I had the same thing starting a local server. I had to enable 'cheats 1' in console for them to work normally after spawning them beforehand.

  • GhoulofGSG9GhoulofGSG9 Join Date: 2013-03-31 Member: 184566Members, Super Administrators, Forum Admins, Forum Moderators, NS2 Developer, NS2 Playtester, Squad Five Blue, Squad Five Silver, Reinforced - Supporter, WC 2013 - Supporter, Pistachionauts
    edited August 2014
    MetaMind wrote: »
    unable to change version locking inside launchpad --> configure.... its not shown the full window

    Pull at the buttom right corner of it ;) Idk but if i test my mods with bots they atack alot i even fixed that marine bots ignored the gorge :D@aeroripper‌ could be right with the cheats 1 guess.

    Bots don't attack in pregame ;)
  • MetaMindMetaMind Join Date: 2012-12-06 Member: 174358Members, Reinforced - Gold
    edited August 2014
    Pulling at corners isnt working on my side... anyway my friend did it now and despite the fact that in concole it shows up "Mounting archived build 266" the mod does still have the same scripterrors and bugs like without version mounting.
Sign In or Register to comment.