Compiling and Packaging With CompilePal

Crowbar

Spiritual preprocessor
aa
Dec 19, 2015
1,455
1,297
You should update the thread title to Compiling, Packing, Building cubemaps, Making navmesh and Repacking with CompilePal. Or rather, give a VMF, get a publishing ready BSP.
 
Jul 26, 2015
697
820
if you have a crash log in your folder that would be helpful

System.IO.FileNotFoundException: The metadata file for BuiltIn could not be found.
at CompilePalX.CompileProcess..ctor(String name)
at CompilePalX.Compilers.CompileExecutable..ctor(String metadata)
at CompilePalX.ConfigurationManager.AssembleParameters()
at CompilePalX.MainWindow..ctor()
at CompilePalX.LaunchWindow.Launch(GameConfiguration config)
at CompilePalX.LaunchWindow.Button_Click(Object sender, RoutedEventArgs e)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.UIElement.RaiseEvent(RoutedEventArgs e)
at System.Windows.Controls.Primitives.ButtonBase.OnClick()
at System.Windows.Controls.Button.OnClick()
at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)
at System.Windows.UIElement.OnMouseLeftButtonUpThunk(Object sender, MouseButtonEventArgs e)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
 

fubarFX

The "raw" in "nodraw"
aa
Jun 1, 2009
1,720
1,978
System.IO.FileNotFoundException: The metadata file for BuiltIn could not be found.
at CompilePalX.CompileProcess..ctor(String name)
at CompilePalX.Compilers.CompileExecutable..ctor(String metadata)
at CompilePalX.ConfigurationManager.AssembleParameters()
at CompilePalX.MainWindow..ctor()
at CompilePalX.LaunchWindow.Launch(GameConfiguration config)
at CompilePalX.LaunchWindow.Button_Click(Object sender, RoutedEventArgs e)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.UIElement.RaiseEvent(RoutedEventArgs e)
at System.Windows.Controls.Primitives.ButtonBase.OnClick()
at System.Windows.Controls.Button.OnClick()
at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)
at System.Windows.UIElement.OnMouseLeftButtonUpThunk(Object sender, MouseButtonEventArgs e)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
alright, go into the "parameters" folder and delete the "builtin" folder. If that doesn't do it, use a clean install of v24, don't overwrite previous compilepal folders.
 

Micnax

Back from the dead (again)
aa
Apr 25, 2009
2,109
1,585
Holy crap!

Edit: I've noticed PACK now places itself after COPY, instead of the other way around. Am I correct in understanding that it'll copy it to the game folder and then pack the original file, or does it do it into the copied file? (The former is annoying, the latter is ideal)
 
Last edited:

ruarai

L1: Registered
Jul 13, 2015
3
5
Holy crap!

Edit: I've noticed PACK now places itself after COPY, instead of the other way around. Am I correct in understanding that it'll copy it to the game folder and then pack the original file, or does it do it into the copied file? (The former is annoying, the latter is ideal)
Haha, you just scared me a little. I thought I was going to have to publish a hotfix real quick.

But no, double checked and PACK uses the copied BSP in the game folder.
 

fubarFX

The "raw" in "nodraw"
aa
Jun 1, 2009
1,720
1,978
Edit: I've noticed PACK now places itself after COPY, instead of the other way around. Am I correct in understanding that it'll copy it to the game folder and then pack the original file, or does it do it into the copied file? (The former is annoying, the latter is ideal)

yeah, it packs the copied file in maps/ now. I've changed that order so that people who wish to pack maps compiled outside of compilepal have an easier time doing so.
 

AlienRadar

L1: Registered
Sep 6, 2015
17
2
I have 2 questions.
1) Is it only for TF2, or CS:GO/HL2?
2) For cubemaps, how do you pack them in? Do you compile, build cubemaps, then pack?
 

Startacker!

WANT ME TO BE REAL? MAKE ME.
aa
Jun 15, 2013
647
1,197
I have 2 questions.
1) Is it only for TF2, or CS:GO/HL2?
2) For cubemaps, how do you pack them in? Do you compile, build cubemaps, then pack?
1. It's for all Source games, as far as my testing.
2. There should be an option to build cubemaps when compiling with compilepal. But yes, that's how you would do it normally.
 

AlienRadar

L1: Registered
Sep 6, 2015
17
2
1. It's for all Source games, as far as my testing.
2. There should be an option to build cubemaps when compiling with compilepal. But yes, that's how you would do it normally.
Ahh, ok. Wasn't sure if there was a built-in cubemap generator.
 

Yrr

An Actual Deer
aa
Sep 20, 2015
1,308
2,743
if you weren't using compilepal's cubemap generation i'd personally recommend packing in compilepal and then building cubemaps afterwards

cubemaps pack themselves when built
 

B!scuit

L4: Comfortable Member
Aug 12, 2016
196
267
I've found a Compilepal bug I find absolutely hilarious:
hilarious_packing_bug.jpg
Model gibs don't get packed automatically! (but the error models appear to have identical physics behaviour to the missing models)
This mostly affects Frontline explosives and custom MvM models (or any other explosive custom assets)

Sneaking the gib models into the map should make for a decent fix for now (or adding them with VIDE)
 

Pocket

Half a Lambert is better than one.
aa
Nov 14, 2009
4,697
2,581
I'll bet it's even funnier to see them flying all over the place. You should record a video.