Foundry: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
(Updated the Foundry article with new information.)
Line 6: Line 6:
== Overview ==
== Overview ==


'''Foundry''' is an unreleased in-game tool (using the same framework as the [[:Category:Particle System|Particle editor]]) that appears to be related to editing the [[entity lump]] of already-compiled maps, then saving either to a [[Patching levels with lump files|LMP file]] or the original VMF.
'''Foundry'''  
Foundry is an engine tool that allows two-way communication between Hammer and the engine. You can sync your Hammer and game viewports, remove/add point and brush entities in real time from both the engine and Hammer sides, have a limited degree of brush editing preview, and more.  


It was mistakenly released during the 2007 Team Fortress 2 beta, though nobody seems to have got it working before the whole tools system was deactivated and it is incompatible with the current build of the engine.
When Foundry is loaded, it will load both Hammer (tied to the engine process) and the Foundry toolset.
[[File:Foundry showcase.png|200px|framed|right|Foundry in action on the Source Filmmaker engine branch.]]




== Foundry Mode ==
When enabled, this should allow the developer to send information between the [[Hammer Foundry Menu]] and the engine. Much of the required bits are in the {{as}}[[Authoring_Tools/SDK (Alien Swarm)|Alien Swarm Authoring Tools]] though lacking the foundry.dll, thus preventing anyone from ever using the tool.


'''engine commands'''
== History ==
Foundry originally operated off of the tool module foundry.dll. This was mistakenly released during the 2007 Team Fortress 2 beta, though nobody seems to have got this version working before the whole tools system was deactivated and it is incompatible with the current build of the engine. Foundry.dll is also present in Black Mesa, but is just a placeholder dummy module.


*foundry_engine_get_mouse_control
Facepunch user Narry discovered that in the L4D2 engine branch and its descendants, the Foundry code was merged into Hammer's own DLL, hammer_dll.dll. By placing this DLL in the tools folder of the game, you can load Foundry using '''"toolload hammer_dll"''' in console, as long as you launch with -foundrymode and -tools.
*foundry_engine_release_mouse_control
*foundry_select_entity
*foundry_sync_hammer_view
*foundry_update_entity




== left4dead\resource\toolfoundry_english.txt ==
== Loading Foundry ==


<pre>"lang"  
Foundry can be used by running with -foundrymode and -tools in the command line. You must then run '''"toolload hammer_dll"''' in console. {{note|You must make sure to copy hammer_dll.dll from the bin folder to the bin/tools folder first!}}
{  
"Language" "English"
"Tokens"
{  
"FoundryNoFile" "No .VMF loaded"
"FoundryProperties" "Entity Properties"
"FoundryEntityReport" "Entity Report"


"FoundryDeleteObjects" "Delete Objects?"
"FoundryDeleteObjectsMsg" "Are you sure you want to delete the selected objects?"
"FoundryProperties" "Properties"
"FoundryEntityReport" "Entity Report"
"FoundryViewDefault" "Default Layout"
"FoundryViewDrawHammerEntities" "Draw Hammer Entities"
"FoundryViewDrawHammerModels" "Draw Hammer Models"
"FoundryViewDrawGameEntities" "Draw Game Entities"
"FoundrySyncHammerView" "Sync Hammer View To Engine View"
"FoundryViewDrawEntityHighlights" "Draw Entity Highlights"
"FoundryReload" "Reload map"
"FoundryUpdateHammerEntity" "Update entity position in Hammer"
"FoundryReloadFromSave" "Reload from quicksave"
"FoundryReloadReplaceEnts" "Reload from quicksave + slam selected ents"
}
}  </pre>
== Spelunking ==
The following strings can be found in Foundry.dll:
func_occluder worldspawn keyvalues vmf entities disconnect; map %s .vmf \content\ \maps\ \game\ CFoundryDoc::LoadFromFile "classname" } "%s"  editorType  "id" "%d" { FoundryTool CFoundryTool CBaseToolSystem Hr '''Resource/BoxRocket.res''' BoxRocket CFoundryViewMenuButton CToolMenuButton CFoundryToolMenuButton *  #FoundryNoFile #ToolHide Command command HideActionMenu ActionMenu OnRecent quit cfg/foundry.txt Foundry OnNew bsp OnClose OnExit OnQuit *.vmf Valve VMF File (*.vmf) foundry_vmf_session '''Choose Valve VMF File''' *.bsp Valve BSP File (*.bsp) foundry_bsp_session '''Choose Valve BSP File map''' respawn_entities load quick vgui/tools/sampletool/sampletool_logo '''#FoundryEntityReport''' #FoundryProperties EntityReportPanel entityreport properties Fatal error loading '%s' [ '%s' ] - %i operations %i operations in stack OnOpen nSave OnSaveAs OnCloseNoSave OnMarkNotDirty undo #undo_help redo #redo_help ReloadMap ReloadFromSave OnToggleProperties OnToggleEntityReport OnDefaultLayout _placeholder info _visible _visible info other other info editor info editor type info id id info type type info name name info vmfEntity '''DmeEditorTypeDictionary''' OnDescribeUndo OnRedo OnUndo OnTool resource/toolfoundry_%language%.txt reloadsave reload '''#FoundryReloadFromSave''' #FoundryReload
wantsToBeDrawnInEngine visibleDmeVMFEntity CEntityReportPanel vgui::EditablePanel FilterValue FilterKey FilterClass Exact FilterByType FilterByHidden FilterByClass FilterByKeyvalue entity ShowProperties No '''DeleteEntities''' Yes #FoundryDeleteObjects #FoundryDeleteObjectsMsg delete panel node <no class> <no name> TextChanged ButtonToggled CheckButtonChecked RadioButtonChecked Delete Entities state resource/entityreportpanel.res '''BrushRadio PointRadio EverythingRadio''' ClassNameComboBox ValueTextEntry KeyTextEntry ExactCheck HiddenCheck KeyvalueCheck ClassnameCheck No Entities Class Name Name Entities ToolGeneral cfg/Foundry.kb Hold hold '''Exponential Decay exponential_decay Catmull-Rom (Tangent) catmullrom_tangent Catmull-Rom (Norm) catmullrom_normalize Catmull-Rom catmullrom Simple Cubic simple_cubic Kochanek-Bartels Late kochanek_late Kochanek-Bartels Early kochanek_early Kochanek-Bartels kochanek Linear Interp. linear_interp B-Spline bspline Ease In/Out easeinout Ease Out easeout Ease In easein Catmull-Rom (Norm X) catmullrom_normalize_x''' Default default @@%s <-> %s curve_%s_to_curve_%s Unknown interpolation type %d Software\Valve\%s %s\Settings MessageBox Frame OnCancel #MessageBox_Cancel OnOk #MessageBox_OK


===Engine Commands (some of these are only defined when Foundry is loaded)===
<pre>
"cl_foundry_ShowEntityHighlights" = "1" client                                 
"foundry_auto_pause" = "2"                                                      - If 1, Foundry pauses the game when the engine window loses focus. If 2, Foundry
"foundry_draw_hammer_entities" = "1"                                           
"foundry_draw_hammer_models" = "0"                                             
"foundry_engine_get_mouse_control"  game                                        - Give the engine control of the mouse.
"foundry_engine_release_mouse_control"  game                                    - Give the control of the mouse back to Hammer.
"foundry_move_focus_to_engine"                                                  - Send focus to the engine.
"foundry_remove_selected"                                                        - Remove selected entities.
"foundry_select_entity"  game                                                    - Select the entity under the crosshair or select entities with the specified name
"foundry_send_ents_to_engine"                                                    - Send selected entities in Hammer into the engine.
"foundry_spawn_visgroup"                                                        - Spawn all the entities in the specified visgroup.
"foundry_sync_engine_view"                                                      - Move engine's 3D view to the same position as Hammer's 3D view.
"foundry_sync_hammer_view"  game                                                - Move Hammer's 3D view to the same position as the engine's 3D view.
"foundry_update_entity"  game                                                    - Updates the entity's position/angles when in edit mode
*foundry_engine_release_mouse_control
*foundry_select_entity
*foundry_sync_hammer_view
*foundry_update_entity
</pre>
===Confirmed Working Games===
*{{sfm}} [[Source Filmmaker]] (Unstable. Engine->Hammer communication seems to have issues? Hammer->Engine works fine.)
===Broken Games===
*{{portal2}} [[Portal 2]] (Semi-working, the module loads but loading a map crashes. Object Properties is broken.)
*{{as}} [[Alien Swarm]] (Semi-working, the module loads but loading a map crashes. Object Properties is broken.)
*{{csgo}} [[Counter-Strike: Global Offensive]] (Semi-working, the module loads but it is ASSUMED that loading a map crashes based on similar behavior to [[Portal 2]])
{{SDKTools}}
{{SDKTools}}
[[Category:Unreleased]]

Revision as of 21:57, 12 January 2018

Broom icon.png
This article or section needs to be cleaned up to conform to a higher standard of quality.
For help, see the VDC Editing Help and Wikipedia cleanup process. Also, remember to check for any notes left by the tagger at this article's talk page.

Stub

This article or section is a stub. You can help by expanding it.


Overview

Foundry Foundry is an engine tool that allows two-way communication between Hammer and the engine. You can sync your Hammer and game viewports, remove/add point and brush entities in real time from both the engine and Hammer sides, have a limited degree of brush editing preview, and more.

When Foundry is loaded, it will load both Hammer (tied to the engine process) and the Foundry toolset.

Foundry in action on the Source Filmmaker engine branch.


History

Foundry originally operated off of the tool module foundry.dll. This was mistakenly released during the 2007 Team Fortress 2 beta, though nobody seems to have got this version working before the whole tools system was deactivated and it is incompatible with the current build of the engine. Foundry.dll is also present in Black Mesa, but is just a placeholder dummy module.

Facepunch user Narry discovered that in the L4D2 engine branch and its descendants, the Foundry code was merged into Hammer's own DLL, hammer_dll.dll. By placing this DLL in the tools folder of the game, you can load Foundry using "toolload hammer_dll" in console, as long as you launch with -foundrymode and -tools.


Loading Foundry

Foundry can be used by running with -foundrymode and -tools in the command line. You must then run "toolload hammer_dll" in console.

Note.pngNote:You must make sure to copy hammer_dll.dll from the bin folder to the bin/tools folder first!


Engine Commands (some of these are only defined when Foundry is loaded)

"cl_foundry_ShowEntityHighlights" = "1" client                                  
"foundry_auto_pause" = "2"                                                       - If 1, Foundry pauses the game when the engine window loses focus. If 2, Foundry 
"foundry_draw_hammer_entities" = "1"                                            
"foundry_draw_hammer_models" = "0"                                              
"foundry_engine_get_mouse_control"  game                                         - Give the engine control of the mouse.
"foundry_engine_release_mouse_control"  game                                     - Give the control of the mouse back to Hammer.
"foundry_move_focus_to_engine"                                                   - Send focus to the engine.
"foundry_remove_selected"                                                        - Remove selected entities.
"foundry_select_entity"  game                                                    - Select the entity under the crosshair or select entities with the specified name
"foundry_send_ents_to_engine"                                                    - Send selected entities in Hammer into the engine.
"foundry_spawn_visgroup"                                                         - Spawn all the entities in the specified visgroup.
"foundry_sync_engine_view"                                                       - Move engine's 3D view to the same position as Hammer's 3D view.
"foundry_sync_hammer_view"  game                                                 - Move Hammer's 3D view to the same position as the engine's 3D view.
"foundry_update_entity"  game                                                    - Updates the entity's position/angles when in edit mode
*foundry_engine_release_mouse_control
*foundry_select_entity
*foundry_sync_hammer_view
*foundry_update_entity

Confirmed Working Games

  • Source Filmmaker Source Filmmaker (Unstable. Engine->Hammer communication seems to have issues? Hammer->Engine works fine.)

Broken Games

  • Portal 2 Portal 2 (Semi-working, the module loads but loading a map crashes. Object Properties is broken.)
  • Alien Swarm Alien Swarm (Semi-working, the module loads but loading a map crashes. Object Properties is broken.)
  • Counter-Strike: Global Offensive Counter-Strike: Global Offensive (Semi-working, the module loads but it is ASSUMED that loading a map crashes based on similar behavior to Portal 2)