Pain Day III #1846
garrynewman
announced in
Announcements
Pain Day III
#1846
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Welcome to Pain Day 3. Your game addons are now automatically hidden in the menus until you post a new update.
Summary
As our code has evolved, older ways of doing things become obsolete. The changes in this update are mostly down to us wanting to get the Tools system working better with Game addons, so we're moving things around to facilitate that a bit better.
The Library system was one of the first systems we added. It is no longer needed. You don't need to mark classes with
[Library]
to make them able to be created.TypeLibrary
has now replaced Library. The issue for us internally was that Library was tied to the game code, so it was unusable in Tools. Now TypeLibrary is able to be used in both Tools and Game, creating some synergy.We were increasingly using
System.ComponentModel
to mark up properties with name, description, grouping, help, icons. While that worked, and was nice, we've added some attributes to make that experience easier, without battling namespaces. These attributes work withDisplayInfo
and the newTypeLibrary.GetDescription
.Creating Decals, Surfaces, Clothing, SoundEvents is now done in the new asset browser, by right clicking a folder and going to Create. Inspector has been removed.
The ConVar system was reconfigured to make it feasible to add convars/commands to Tools and Engine.
I started removing some things from the base addon. Namely Crosshair, ScreenShake, KillFeed, Nametags. The Base addon has got a new folder called obsolete, and a bunch of stuff has been moved in there.
Upgrade Guide
[ServerCmd]
becomes[ConCmd.Server]
(and Admin, Client)[ServerVar]
becomes[ConVar.Server]
(and Client)ClassInfo
was removed from Entity - you probably want.ClassName
ClassInfo.Title
,ClassInfo.Description
- maybe tryDisplayInfo.For()
[Library( Spawnable = true )
becomes[Spawnable]
Library.Create
becomesTypeLibrary.Create
Library.GetAttribute
becomesTypeLibrary.GetDescription
DebugOverlay.*
some argument orders made consistentClothing.Container
becomesClothingContainer
Sandbox.ScreenShake
deleted - implement your own screenshakeSandbox.UI.Crosshair
deleted - implement your own crosshairSandbox.UI.KillFeed
deleted - implement your own (or paste it from another addon)Sandbox.UI.NameTags
deleted - implement your ownAnimEntity
becomesAnimatedEntity
Attack1
becomesPrimaryAttack
Attack2
becomesSecondaryAttack
[HammerEntity]
on ents you want in Hammer.Hammer
namespace mostly becomesSandboxEditor
[Hammer.Skip]
becomes[HideInEditor]
[Title( x )]
to dissuade usage of[Display( Name = x )]
VrHand.AngularVelocity
type changed toAngles
Beta Was this translation helpful? Give feedback.
All reactions