mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2025-06-03 18:31:12 +00:00
Default thing arguments were not set when creating a new thing, only when changing thing type in Edit Things window.
This commit is contained in:
parent
3e5f85dc8f
commit
21889a98e7
3 changed files with 17 additions and 14 deletions
|
@ -545,6 +545,16 @@ namespace CodeImp.DoomBuilder.Config
|
|||
t.Type = defaultthingtype;
|
||||
t.Rotate(defaultthingangle);
|
||||
foreach(string f in defaultthingflags) t.SetFlag(f, true);
|
||||
|
||||
//mxd. Set default arguments
|
||||
ThingTypeInfo tti = General.Map.Data.GetThingInfoEx(t.Type);
|
||||
if (tti != null) {
|
||||
t.Args[0] = (int)tti.Args[0].DefaultValue;
|
||||
t.Args[1] = (int)tti.Args[1].DefaultValue;
|
||||
t.Args[2] = (int)tti.Args[2].DefaultValue;
|
||||
t.Args[3] = (int)tti.Args[3].DefaultValue;
|
||||
t.Args[4] = (int)tti.Args[4].DefaultValue;
|
||||
}
|
||||
}
|
||||
|
||||
// This attempts to find the default drawing settings
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue