- Joined
- Jul 18, 2010
- Messages
- 2,377
Introduction
A TOC file is a file listing one or more fdf (frame definition files). Each line is a path to one fdf. Each fdf is an own file. In Warcraft 3 this TOC-Files are used to load the fdfs beeing listed.
After a fdf was loaded into the game using a TOC lisiting it, main-Frames defined in the fdf can be created. Main-Frames are in my talking Frame definitions outside of Blocks { }.
A TOC-File is not case sensitve.
One can load a TOC-File using the native provided in Warcraft 3 1.31.
native BlzLoadTOCFile takes string TOCFile returns boolean
it returns true if the TOC file was loaded successfuly. It might be smart to create a new function telling your, if a TOC load failed/succeeded.
On default "ui/framedef/framedef.toc" is loaded, it contains most default fdf of warcraft 3.
Code:
UI\FrameDef\GlobalStrings.fdf
UI\FrameDef\InfoPanelStrings.fdf
UI\FrameDef\NetworkStrings.fdf
UI\FrameDef\DateStrings.fdf
UI\FrameDef\Glue\DialogWar3.fdf
UI\FrameDef\Glue\MapInfoPane.fdf
UI\FrameDef\Glue\AdvancedOptionsDisplay.fdf
UI\FrameDef\Glue\AdvancedOptionsPane.fdf
UI\FrameDef\Glue\ListBoxWar3.fdf
UI\FrameDef\Glue\MapListBox.fdf
UI\FrameDef\Glue\DecoratedMapListBox.fdf
UI\FrameDef\Glue\MapPreferenceBox.fdf
UI\FrameDef\Glue\CheckListBox.fdf
UI\FrameDef\Glue\MainMenu.fdf
UI\FrameDef\Glue\MovieScreen.fdf
UI\FrameDef\Glue\Loading.fdf
UI\FrameDef\Glue\LoadSavedGameScreen.fdf
UI\FrameDef\Glue\OptionsMenu.fdf
UI\FrameDef\Glue\SinglePlayerMenu.fdf
UI\FrameDef\Glue\ViewReplayScreen.fdf
UI\FrameDef\Glue\CustomCampaignMenu.fdf
UI\FrameDef\Glue\CampaignMenu.fdf
UI\FrameDef\Glue\TeamSetup.fdf
UI\FrameDef\Glue\PlayerSlot.fdf
UI\FrameDef\Glue\Skirmish.fdf
UI\FrameDef\Glue\ScoreScreen.fdf
UI\FrameDef\Glue\LocalMultiplayerJoin.fdf
UI\FrameDef\Glue\LocalMultiplayerCreate.fdf
UI\FrameDef\Glue\LocalMultiplayerLoad.fdf
UI\FrameDef\Glue\GameChatroom.fdf
UI\FrameDef\Glue\CampaignListBox.fdf
UI\FrameDef\Glue\BattleNetMain.fdf
UI\FrameDef\Glue\BattleNetMatchmakerPanel.fdf
UI\FrameDef\Glue\BattleNetNewsBox.fdf
UI\FrameDef\Glue\BattleNetUserListBox.fdf
UI\FrameDef\Glue\BattleNetChatPanel.fdf
UI\FrameDef\Glue\BattleNetChatActionMenu.fdf
UI\FrameDef\Glue\BattleNetStandardPanel.fdf
UI\FrameDef\Glue\BattleNetTeamPanel.fdf
UI\FrameDef\Glue\BattleNetTeamInvitation.fdf
UI\FrameDef\Glue\BattleNetProfilePanel.fdf
UI\FrameDef\Glue\BattleNetCustomJoinPanel.fdf
UI\FrameDef\Glue\BattleNetCustomCreatePanel.fdf
UI\FrameDef\Glue\BattleNetCustomLoadPanel.fdf
UI\FrameDef\Glue\BattleNetScheduledGame.fdf
UI\FrameDef\Glue\BattleNetChatroom.fdf
UI\FrameDef\Glue\BattleNetFriendsListBox.fdf
UI\FrameDef\Glue\BattleNetFriendsPane.fdf
UI\FrameDef\Glue\BattleNetClanMateListBox.fdf
UI\FrameDef\Glue\BattleNetClanPane.fdf
UI\FrameDef\Glue\BattleNetClanInvitation.fdf
UI\FrameDef\Glue\BattleNetStatusBox.fdf
UI\FrameDef\Glue\BattleNetIconSelectBox.fdf
UI\FrameDef\UI\ConsoleUI.fdf
UI\FrameDef\UI\AllianceSlot.fdf
UI\FrameDef\UI\AllianceDialog.fdf
UI\FrameDef\UI\ChatDialog.fdf
UI\FrameDef\UI\LogDialog.fdf
UI\FrameDef\UI\EscMenuMainPanel.fdf
UI\FrameDef\UI\EscMenuOptionsPanel.fdf
UI\FrameDef\UI\EscMenuSaveGamePanel.fdf
UI\FrameDef\UI\GameResultDialog.fdf
UI\FrameDef\UI\UpperButtonBar.fdf
UI\FrameDef\UI\ResourceBar.fdf
UI\FrameDef\UI\SimpleInfoPanel.fdf
UI\FrameDef\UI\SuspendDialog.fdf
UI\FrameDef\UI\UnresponsiveDialog.fdf
UI\FrameDef\UI\ReplayPanel.fdf
UI\FrameDef\UI\ObserverPanel.fdf
UI\FrameDef\UI\QuestDialog.fdf
UI\FrameDef\UI\TimerDialog.fdf
UI\FrameDef\UI\Leaderboard.fdf
UI\FrameDef\UI\Multiboard.fdf
UI\FrameDef\UI\CinematicPanel.fdf
UI\FrameDef\UI\ScriptDialog.fdf
UI\FrameDef\UI\GameSaveSplashDialog.fdf
UI\FrameDef\UI\BrowserFrame.fdf
Although there are 3 further default fdf, providing quite useful basic frame templates which might be good to have in your map, if one does not create own custom fdf.
Code:
ui\framedef\ui\escmenutemplates.fdf[
ui\framedef\glue\standardtemplates.fdf
ui\framedef\glue\battlenettemplates.fdf
The path written in the TOC file is the file the game will load. For imported fdf write the path you imported it into your map.
It is recommented to add an empty line at the end of your TOC-Files text. It failed on the ptr without the empty ending line.
Example
"myStatusBar.toc" imported to "war3mapImported\myStatusBar.toc"
"myStatusbar.fdf" imported to "war3mapImported\myStatusBar.fdf"
TOC-Content
in this example this line of code would load the imported TOC-File.
call BlzLoadTOCFile("war3mapimported\\mystatusbar.toc")
TOC-Files are important when you want to create new frames or load further fdf.
Edit: Added a zip containing "Templates.toc" it is loading the 2 templates mentioned.
Other UI-Frame Tutorials
The following links might provide more insight into this subject.
[JASS/AI] - UI: Positionate Frames (important)
Default Names for BlzGetFrameByName (Access to Existing game-Frames)
[JASS/AI] - UI: List - Default MainFrames (built in CreateAble)
Attachments
Last edited: