BrawlCrate v0.41
Wii File Editor
Loading...
Searching...
No Matches
Public Member Functions | Static Protected Member Functions | Properties | List of all members
BrawlCrate.NodeWrappers.SCN0Wrapper Class Reference
Inheritance diagram for BrawlCrate.NodeWrappers.SCN0Wrapper:
BrawlCrate.NodeWrappers.GenericWrapper BrawlCrate.NodeWrappers.BaseWrapper BrawlCrate.NodeWrappers.MultiSelectableWrapper

Public Member Functions

 SCN0Wrapper ()
 
void newLightSet ()
 
void newAmbLight ()
 
void newLight ()
 
void newFogSet ()
 
void newCamera ()
 
void replaceKeepCamera ()
 
- Public Member Functions inherited from BrawlCrate.NodeWrappers.GenericWrapper
 GenericWrapper (IWin32Window owner)
 
 GenericWrapper ()
 
virtual void Sort ()
 
void MoveUp ()
 
virtual void MoveUp (bool select)
 
void MoveDown ()
 
virtual void MoveDown (bool select)
 
void DeleteSelected ()
 
void ExportSelected ()
 
virtual string Export ()
 
virtual void OnExport (string outPath)
 
virtual void Replace ()
 
virtual void OnReplace (string inStream)
 
void Restore ()
 
virtual void Delete ()
 
void Rename ()
 
virtual ResourceNode Duplicate ()
 
virtual ResourceNode Duplicate (bool changeName)
 
- Public Member Functions inherited from BrawlCrate.NodeWrappers.BaseWrapper
void Link (ResourceNode res)
 
void Unlink ()
 

Static Protected Member Functions

static void newLightSetAction (object sender, EventArgs e)
 
static void newAmbLightAction (object sender, EventArgs e)
 
static void newLightAction (object sender, EventArgs e)
 
static void newFogSetAction (object sender, EventArgs e)
 
static void newCameraAction (object sender, EventArgs e)
 
static void ReplaceKeepCameraAction (object sender, EventArgs e)
 
- Static Protected Member Functions inherited from BrawlCrate.NodeWrappers.GenericWrapper
static void MoveUpAction (object sender, EventArgs e)
 
static void MoveDownAction (object sender, EventArgs e)
 
static void ExportAction (object sender, EventArgs e)
 
static void ExportSelectedAction (object sender, EventArgs e)
 
static void DeleteSelectedAction (object sender, EventArgs e)
 
static void DuplicateAction (object sender, EventArgs e)
 
static void ReplaceAction (object sender, EventArgs e)
 
static void RestoreAction (object sender, EventArgs e)
 
static void DeleteAction (object sender, EventArgs e)
 
static void RenameAction (object sender, EventArgs e)
 
static void SortAction (object sender, EventArgs e)
 
- Static Protected Member Functions inherited from BrawlCrate.NodeWrappers.BaseWrapper
static T GetInstance< T > ()
 
static IEnumerable< T > GetInstances< T > ()
 

Properties

override string ExportFilter [get]
 
- Properties inherited from BrawlCrate.NodeWrappers.GenericWrapper
virtual ContextMenuStrip MultiSelectMenuStrip [get]
 
virtual string DefaultName [get]
 
virtual string ExportFilter [get]
 
virtual string ImportFilter [get]
 
virtual string ReplaceFilter [get]
 
- Properties inherited from BrawlCrate.NodeWrappers.BaseWrapper
ResourceNode Resource [get]
 
virtual ? Color DefaultBackColor [get]
 
virtual ? Color DefaultForeColor [get]
 
- Properties inherited from BrawlCrate.NodeWrappers.MultiSelectableWrapper
ContextMenuStrip MultiSelectMenuStrip [get]
 

Additional Inherited Members

- Static Public Member Functions inherited from BrawlCrate.NodeWrappers.BaseWrapper
static BaseWrapper[] GetAllNodes (BaseWrapper root)
 
static BaseWrapper Wrap (ResourceNode node)
 
static BaseWrapper Wrap (IWin32Window owner, ResourceNode node)
 
- Static Public Attributes inherited from BrawlCrate.NodeWrappers.BaseWrapper
static IWin32Window _owner
 
- Protected Member Functions inherited from BrawlCrate.NodeWrappers.BaseWrapper
 BaseWrapper ()
 
- Protected Attributes inherited from BrawlCrate.NodeWrappers.BaseWrapper
bool _discovered
 
ResourceNode _resource
 
- Static Protected Attributes inherited from BrawlCrate.NodeWrappers.BaseWrapper
static readonly ContextMenuStrip _emptyMenu = new ContextMenuStrip()
 

Constructor & Destructor Documentation

◆ SCN0Wrapper()

BrawlCrate.NodeWrappers.SCN0Wrapper.SCN0Wrapper ( )
inline
119 {
120 ContextMenuStrip = _menu;
121 }

Member Function Documentation

◆ newAmbLight()

void BrawlCrate.NodeWrappers.SCN0Wrapper.newAmbLight ( )
inline
134 {
135 SCN0EntryNode node = ((SCN0Node) _resource).CreateResource<SCN0AmbientLightNode>("NewAmbientLight");
136 BaseWrapper res = FindResource(node, true);
137 res.EnsureVisible();
138 //res.TreeView.SelectedNode = res;
139 }
ResourceNode _resource
Definition: BaseWrapper.cs:76
BaseWrapper()
Definition: BaseWrapper.cs:79
Definition: SCN0AmbientLightNode.cs:11
Definition: SCN0GroupNode.cs:236
Definition: SCN0Node.cs:9

◆ newAmbLightAction()

static void BrawlCrate.NodeWrappers.SCN0Wrapper.newAmbLightAction ( object  sender,
EventArgs  e 
)
inlinestaticprotected
70 {
71 GetInstance<SCN0Wrapper>().newAmbLight();
72 }

◆ newCamera()

void BrawlCrate.NodeWrappers.SCN0Wrapper.newCamera ( )
inline
158 {
159 SCN0EntryNode node = ((SCN0Node) _resource).CreateResource<SCN0CameraNode>("NewCamera");
160 BaseWrapper res = FindResource(node, true);
161 res.EnsureVisible();
162 //res.TreeView.SelectedNode = res;
163 }
Definition: SCN0CameraNode.cs:12

◆ newCameraAction()

static void BrawlCrate.NodeWrappers.SCN0Wrapper.newCameraAction ( object  sender,
EventArgs  e 
)
inlinestaticprotected
85 {
86 GetInstance<SCN0Wrapper>().newCamera();
87 }

◆ newFogSet()

void BrawlCrate.NodeWrappers.SCN0Wrapper.newFogSet ( )
inline
150 {
151 SCN0EntryNode node = ((SCN0Node) _resource).CreateResource<SCN0FogNode>("NewFogSet");
152 BaseWrapper res = FindResource(node, true);
153 res.EnsureVisible();
154 //res.TreeView.SelectedNode = res;
155 }
Definition: SCN0FogNode.cs:13

◆ newFogSetAction()

static void BrawlCrate.NodeWrappers.SCN0Wrapper.newFogSetAction ( object  sender,
EventArgs  e 
)
inlinestaticprotected
80 {
81 GetInstance<SCN0Wrapper>().newFogSet();
82 }

◆ newLight()

void BrawlCrate.NodeWrappers.SCN0Wrapper.newLight ( )
inline
142 {
143 SCN0EntryNode node = ((SCN0Node) _resource).CreateResource<SCN0LightNode>("NewLight");
144 BaseWrapper res = FindResource(node, true);
145 res.EnsureVisible();
146 //res.TreeView.SelectedNode = res;
147 }
Definition: SCN0LightNode.cs:14

◆ newLightAction()

static void BrawlCrate.NodeWrappers.SCN0Wrapper.newLightAction ( object  sender,
EventArgs  e 
)
inlinestaticprotected
75 {
76 GetInstance<SCN0Wrapper>().newLight();
77 }

◆ newLightSet()

void BrawlCrate.NodeWrappers.SCN0Wrapper.newLightSet ( )
inline
126 {
127 SCN0EntryNode node = ((SCN0Node) _resource).CreateResource<SCN0LightSetNode>("NewLightSet");
128 BaseWrapper res = FindResource(node, true);
129 res.EnsureVisible();
130 //res.TreeView.SelectedNode = res;
131 }
Definition: SCN0LightSetNode.cs:8

◆ newLightSetAction()

static void BrawlCrate.NodeWrappers.SCN0Wrapper.newLightSetAction ( object  sender,
EventArgs  e 
)
inlinestaticprotected
65 {
66 GetInstance<SCN0Wrapper>().newLightSet();
67 }

◆ replaceKeepCamera()

void BrawlCrate.NodeWrappers.SCN0Wrapper.replaceKeepCamera ( )
inline
166 {
167 if (Program.OpenFile(ReplaceFilter, out string inPath))
168 {
169 using (SCN0Node ext = NodeFactory.FromFile(null, inPath, typeof(SCN0Node)) as SCN0Node)
170 {
171 if (ext == null)
172 {
173 MessageBox.Show("The selected SCN0 file could not be read.");
174 return;
175 }
176 ext.Populate();
177 ext.CameraGroup.Children.Clear();
178 foreach (ResourceNode n in ((SCN0Node)Resource).CameraGroup.Children)
179 {
180 ext.CameraGroup.AddChild(n);
181 }
182
183 string s = Path.GetTempFileName() + ".scn0";
184 ext.Export(s);
185 Resource.Replace(s);
186 }
187 }
188 }
ResourceNode Resource
Definition: BaseWrapper.cs:77
virtual string ReplaceFilter
Definition: GenericWrapper.cs:250
override void Export(string outPath)
Definition: BRRESNode.cs:1124
Definition: NodeFactory.cs:18
static ResourceNode FromFile(ResourceNode parent, string path)
Definition: NodeFactory.cs:69
Definition: ResourceNode.cs:129
virtual void Replace(string fileName)
Definition: ResourceNode.cs:829
virtual void AddChild(ResourceNode child)
Definition: ResourceNode.cs:757
List< ResourceNode > Children
Definition: ResourceNode.cs:262
void Populate(int levels=-1)
Definition: ResourceNode.cs:613
SCN0GroupNode CameraGroup
Definition: SCN0Node.cs:65

◆ ReplaceKeepCameraAction()

static void BrawlCrate.NodeWrappers.SCN0Wrapper.ReplaceKeepCameraAction ( object  sender,
EventArgs  e 
)
inlinestaticprotected
90 {
91 GetInstance<SCN0Wrapper>().replaceKeepCamera();
92 }

Property Documentation

◆ ExportFilter

override string BrawlCrate.NodeWrappers.SCN0Wrapper.ExportFilter
get

The documentation for this class was generated from the following file: