本文整理汇总了C#中WinterLeaf.Engine.Classes.View.Creators.ObjectCreator类的典型用法代码示例。如果您正苦于以下问题:C# ObjectCreator类的具体用法?C# ObjectCreator怎么用?C# ObjectCreator使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ObjectCreator类属于WinterLeaf.Engine.Classes.View.Creators命名空间,在下文中一共展示了ObjectCreator类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: StartSelectedDemo
public static void StartSelectedDemo()
{
// first unit is filename
GuiTextListCtrl RecordingsDlgList = "RecordingsDlgList";
int sel = RecordingsDlgList.getSelectedId();
string rowText = RecordingsDlgList.getRowTextById(sel);
string file = omni.sGlobal["$currentMod"] + "/recordings/" + omni.Util.getField(rowText, 0) + ".rec";
GameConnection ServerConnection = new ObjectCreator("GameConnection", "ServerConnection").Create();
((SimGroup) "RootGroup").add(ServerConnection);
// Start up important client-side stuff, such as the group
// for particle emitters. This doesn't get launched during a demo
// as we short circuit the whole mission loading sequence.
mission.clientStartMission();
if (ServerConnection.playDemo(file))
{
((GuiCanvas) "canvas").setContent("PlayGui");
((GuiCanvas) "canvas").popDialog("RecordingsDlg");
ServerConnection.call("prepDemoPlayback");
}
else
{
messageBox.MessageBoxOK("Playback Failed", "Demo playback failed for file '" + file + "'.", "");
if ("ServerConnection".isObject())
"ServerConnection".delete();
}
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:30,代码来源:recordings.cs
示例2: onWorldEditorStartup
public override void onWorldEditorStartup()
{
EditorGui EditorGui = "EditorGui";
base.onWorldEditorStartup();
// Add ourselves to the window menu.
string accel = EditorGui.addToEditorsMenu("Terrain Painter", "", this);
// Add ourselves to the ToolsToolbar
string tooltip = "Terrain Painter (" + accel + ")";
EditorGui.addToToolsToolbar("TerrainPainterPlugin", "TerrainPainterPalette", Util._expandFilename("tools/worldEditor/images/toolbar/paint-terrain"), tooltip);
ActionMap map = new ObjectCreator("ActionMap").Create();
string keyboard = "keyboard";
map.bindCmd(keyboard, "v", "EWTerrainPainterToolbarBrushType->ellipse.performClick();", ""); // Circle Brush
map.bindCmd(keyboard, "b", "EWTerrainPainterToolbarBrushType->box.performClick();", ""); // Box Brush
map.bindCmd(keyboard, "=", "TerrainPainterPlugin.keyboardModifyBrushSize(1);", ""); // +1 Brush Size
map.bindCmd(keyboard, "+", "TerrainPainterPlugin.keyboardModifyBrushSize(1);", ""); // +1 Brush Size
map.bindCmd(keyboard, "-", "TerrainPainterPlugin.keyboardModifyBrushSize(-1);", ""); // -1 Brush Size
map.bindCmd(keyboard, "[", "TerrainPainterPlugin.keyboardModifyBrushSize(-5);", ""); // -5 Brush Size
map.bindCmd(keyboard, "]", "TerrainPainterPlugin.keyboardModifyBrushSize(5);", ""); // +5 Brush Size
for (int i = 0; i < 10; i++)
map.bindCmd(keyboard, i.AsString(), "TerrainPainterPlugin.keyboardSetMaterial(" + (i - 1) + ");", "");
map.bindCmd(keyboard, "0", "TerrainPainterPlugin.keyboardSetMaterial(10);", "");
this.map = map;
//console.Call_Classname("GuiWindowCtrl", "attach", new[] { "TerrainPainter", "TerrainPainterPreview" });
TerrainPainter TerrainPainter = "TerrainPainter";
TerrainPainter.attachTo("TerrainPainterPreview");
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:34,代码来源:TerainPainterPlugin.cs
示例3: initializeDatablockEditor
public static void initializeDatablockEditor()
{
Omni.self.Print(" % Initializing Datablock Editor");
gui.CodeBehind.DatablockEditor.initialize();
DatablockEditorTreeWindow.initialize();
DatablockEditorInspectorWindow.initialize();
DatablockEditorCreatePrompt.initialize();
// Add ourselves to EditorGui, where all the other tools reside
DatablockEditorInspectorWindow oDatablockEditorInspectorWindow = "DatablockEditorInspectorWindow";
oDatablockEditorInspectorWindow.setVisible(false);
DatablockEditorTreeWindow oDatablockEditorTreeWindow = "DatablockEditorTreeWindow";
oDatablockEditorTreeWindow.setVisible(false);
EditorGui EditorGui = "EditorGui";
EditorGui.add("DatablockEditorInspectorWindow");
EditorGui.add("DatablockEditorTreeWindow");
ObjectCreator o = new ObjectCreator("ScriptObject", "DatablockEditorPlugin", typeof (DatablockEditorPlugin));
o["editorGui"] = "EWorldEditor";
o.Create();
DatablockEditorPlugin p = "DatablockEditorPlugin";
p.initialize();
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:25,代码来源:main.cs
示例4: initialize_CS
public static void initialize_CS()
{
ObjectCreator tch = new ObjectCreator("ShaderData", "AL_ShadowVisualizeShader");
tch["DXVertexShaderFile"] = "shaders/common/guiMaterialV.hlsl";
tch["DXPixelShaderFile"] = "shaders/common/lighting/advanced/dbgShadowVisualizeP.hlsl";
tch["OGLVertexShaderFile"] = "shaders/common/gl/guiMaterialV.glsl";
tch["OGLPixelShaderFile"] = "shaders/common/lighting/advanced/gl/dbgShadowVisualizeP.glsl";
tch["pixVersion"] = 2.0;
tch.Create();
tch = new ObjectCreator("CustomMaterial", "AL_ShadowVisualizeMaterial");
tch["shader"] = "AL_ShadowVisualizeShader";
tch["stateBlock"] = "AL_DepthVisualizeState";
tch["sampler[\"shadowMap\"]"] = "#AL_ShadowVizTexture";
tch["sampler[\"depthViz\"]"] = "core/scripts/client/lighting/advanced/depthviz";
tch["pixVersion"] = 2.0;
tch.Create();
SingletonCreator ts = new SingletonCreator("GuiControlProfile", "AL_ShadowLabelTextProfile");
ts["fontColor"] = "0 0 0";
ts["autoSizeWidth"] = true;
ts["autoSizeHeight"] = true;
ts["justify"] = "left";
ts["fontSize"] = 14;
ts.Create();
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:30,代码来源:shadowViz.cs
示例5: initializeDecalEditor
public static void initializeDecalEditor()
{
Omni.self.Print(" % - Initializing Decal Editor");
omni.sGlobal["$decalDataFile"] = "art/decals/managedDecalData.cs";
gui.DecalEditorGui.initialize();
// Add ourselves to EditorGui, where all the other tools reside
DecalEditorGui DecalEditorGui = "DecalEditorGui";
DecalEditorGui.setVisible(false);
DecalEditorGui.DecalPreviewWindow DecalPreviewWindow = "DecalPreviewWindow";
DecalPreviewWindow.setVisible(false);
DecalEditorGui.DecalEditorWindow DecalEditorWindow = "DecalEditorWindow";
DecalEditorWindow.setVisible(false);
EditorGui EditorGui = "EditorGui";
EditorGui.add(DecalEditorGui);
EditorGui.add(DecalEditorWindow);
EditorGui.add(DecalPreviewWindow);
DecalEditorGui.DecalEditorTabBook DecalEditorTabBook = "DecalEditorTabBook";
DecalEditorTabBook.selectPage(0);
ObjectCreator oc = new ObjectCreator("ScriptObject", "DecalEditorPlugin", typeof (DecalEditorPlugin));
oc["editorGui"] = "DecalEditorGui";
oc.Create();
DecalEditorPlugin DecalEditorPlugin = "DecalEditorPlugin";
DecalEditorPlugin.initialize();
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:33,代码来源:main.cs
示例6: initializeRiverEditor
public static void initializeRiverEditor()
{
Omni.self.Print(" % - Initializing River Editor");
gui.RiverEditor.initialize();
RiverEditorGui.initialize();
RiverEditorToolbar.initialize();
// Add ourselves to EditorGui, where all the other tools reside
RiverEditorGui riverEditorGui = "RiverEditorGui";
riverEditorGui.setVisible(false);
RiverEditorToolbar oRiverEditorToolbar = "RiverEditorToolbar";
oRiverEditorToolbar.setVisible(false);
((GuiWindowCollapseCtrl) "RiverEditorOptionsWindow").setVisible(false);
GuiWindowCollapseCtrl RiverEditorTreeWindow = "RiverEditorTreeWindow";
RiverEditorTreeWindow.setVisible(false);
EditorGui EditorGui = "EditorGui";
EditorGui.add("RiverEditorGui");
EditorGui.add("RiverEditorToolbar");
EditorGui.add("RiverEditorOptionsWindow");
EditorGui.add("RiverEditorTreeWindow");
ObjectCreator oRiverEditorPlugin = new ObjectCreator("ScriptObject", "RiverEditorPlugin", typeof (RiverEditorPlugin));
oRiverEditorPlugin["editorGui"] = "RiverEditorGui";
oRiverEditorPlugin.Create();
RiverEditorPlugin RiverEditorPlugin = "RiverEditorPlugin";
RiverEditorPlugin.initialize();
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:33,代码来源:main.cs
示例7: onThrow
public override int onThrow(ShapeBase user, int amount)
{
if (amount == 0)
amount = 1;
if (this["maxInventory"] != string.Empty)
{
if (amount > this["maxInventory"].AsInt())
amount = this["maxInventory"].AsInt();
}
if (!amount.AsBool())
return 0;
user.decInventory(this, amount);
//ShapeBaseShapeBaseDecInventory(player, datablock, amount);
// Construct the actual object in the world, and add it to
// the mission group so it's cleaned up when the mission is
// done. The object is given a random z rotation.
ObjectCreator tch = new ObjectCreator("Item", string.Empty);
tch["datablock"] = this;
tch["rotation"] = "0 0 1 " + (new Random().Next(0, 360));
tch["count"] = amount;
Item item = tch.Create();
((SimSet) "MissionGroup").pushToBack(item);
item.SchedulePop();
return item;
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:33,代码来源:ItemData.cs
示例8: onAdd
public override void onAdd()
{
this.createMenuBar();
ObjectCreator oc = new ObjectCreator("GuiPanel");
oc["internalName"] = "DocumentContainer";
GuiPanel panel = oc.Create();
this.setContent(panel);
int xOffset = 20;
int yOffset = 20;
for (int i = 0; i < 10; i++)
{
ObjectCreator oc1 = new ObjectCreator("GuiWindowCtrl");
oc["extent"] = "200 100";
oc["position"] = xOffset + ' ' + yOffset;
GuiWindowCtrl window = oc1.Create();
panel.add(window);
xOffset += 30;
yOffset += 30;
}
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:27,代码来源:BaseEditorCanvas.ed.cs
示例9: init
public void init()
{
if (!this.contextMenu.isObject())
{
ObjectCreator pop = new ObjectCreator("PopupMenu", "guiTreePop", typeof (MenuBuilder));
pop["isPopup"] = true;
pop["item[0]"] = "Rename" + '\t' + "" + '\t' + "GuiEditorTreeView.showItemRenameCtrl( GuiEditorTreeView.findItemByObjectId( guiTreePop.object ) );";
pop["item[1]"] = "Delete" + '\t' + "" + '\t' + "GuiEditor.deleteControl( guiTreePop.object );";
pop["item[2]"] = "-";
pop["item[3]"] = "Locked" + '\t' + "" + '\t' + "guiTreePop.object.setLocked( !guiTreePop.object.locked ); GuiEditorTreeView.update();";
pop["item[4]"] = "Hidden" + '\t' + "" + '\t' + "guiTreePop.object.setVisible( !guiTreePop.object.isVisible() ); GuiEditorTreeView.update();";
pop["item[5]"] = "-";
pop["item[6]"] = "Add New Controls Here" + '\t' + "" + '\t' + "GuiEditor.setCurrentAddSet( guiTreePop.object );";
pop["item[7]"] = "Add Child Controls to Selection" + '\t' + "" + '\t' + "GuiEditor.selectAllControlsInSet( guiTreePop.object, false );";
pop["item[8]"] = "Remove Child Controls from Selection" + '\t' + "" + '\t' + "GuiEditor.selectAllControlsInSet( guiTreePop.object, true );";
pop["object"] = -1;
this.contextMenu = pop.Create();
}
if (!this.contextMenuMultiSel.isObject())
{
ObjectCreator multiSel = new ObjectCreator("PopupMenu", "", typeof (MenuBuilder));
multiSel["isPopup"] = true;
multiSel["item[0]"] = "Delete" + '\t' + "" + '\t' + "GuiEditor.deleteSelection();";
this.contextMenuMultiSel = multiSel.Create();
}
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:32,代码来源:GuiEditorTreeView.ed.cs
示例10: initialize
public void initialize()
{
ObjectCreator oc_Newobject3 = new ObjectCreator("SimSet", "ForestTools");
ObjectCreator oc_Newobject2 = new ObjectCreator("ForestBrushTool");
oc_Newobject2["internalName"] = "BrushTool";
oc_Newobject2["toolTip"] = "Paint Tool";
oc_Newobject2["buttonImage"] = "tools/forest/images/brushTool";
oc_Newobject3["#Newobject2"] = oc_Newobject2;
ObjectCreator oc_Newobject1 = new ObjectCreator("ForestSelectionTool");
oc_Newobject1["internalName"] = "SelectionTool";
oc_Newobject1["toolTip"] = "Selection Tool";
oc_Newobject1["buttonImage"] = "tools/forest/images/selectionTool";
oc_Newobject3["#Newobject1"] = oc_Newobject1;
oc_Newobject3.Create();
ActionMap map = new ObjectCreator("ActionMap").Create();
map.bindCmd("keyboard", "1", "ForestEditorSelectModeBtn.performClick();", ""); // Select
map.bindCmd("keyboard", "2", "ForestEditorMoveModeBtn.performClick();", ""); // Move
map.bindCmd("keyboard", "3", "ForestEditorRotateModeBtn.performClick();", ""); // Rotate
map.bindCmd("keyboard", "4", "ForestEditorScaleModeBtn.performClick();", ""); // Scale
map.bindCmd("keyboard", "5", "ForestEditorPaintModeBtn.performClick();", ""); // Paint
map.bindCmd("keyboard", "6", "ForestEditorEraseModeBtn.performClick();", ""); // Erase
map.bindCmd("keyboard", "7", "ForestEditorEraseSelectedModeBtn.performClick();", ""); // EraseSelected
map.bindCmd("keyboard", "8", "ForestEditorDropToGroundModeBtn.performClick();", ""); // DropTheBeat
//%map.bindCmd( keyboard, "backspace", "ForestEditorGui.onDeleteKey();", "" );
//%map.bindCmd( keyboard, "delete", "ForestEditorGui.onDeleteKey();", "" );
this.map = map;
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:32,代码来源:ForestEditorPlugin.cs
示例11: initialize
public void initialize()
{
ActionMap map = new ObjectCreator("ActionMap").Create();
map.bindCmd("keyboard", "escape", "ToolsToolbarArray->WorldEditorInspectorPalette.performClick();", "");
map.bindCmd("keyboard", "1", "ShapeEditorNoneModeBtn.performClick();", "");
map.bindCmd("keyboard", "2", "ShapeEditorMoveModeBtn.performClick();", "");
map.bindCmd("keyboard", "3", "ShapeEditorRotateModeBtn.performClick();", "");
//%map.bindCmd( keyboard, "4", "ShapeEditorScaleModeBtn.performClick();", "" ); // not needed for the shape editor
map.bindCmd("keyboard", "n", "ShapeEditorToolbar->showNodes.performClick();", "");
map.bindCmd("keyboard", "t", "ShapeEditorToolbar->ghostMode.performClick();", "");
map.bindCmd("keyboard", "r", "ShapeEditorToolbar->wireframeMode.performClick();", "");
map.bindCmd("keyboard", "f", "ShapeEditorToolbar->fitToShapeBtn.performClick();", "");
map.bindCmd("keyboard", "g", "ShapeEditorToolbar->showGridBtn.performClick();", "");
map.bindCmd("keyboard", "h", "ShapeEdSelectWindow->tabBook.selectPage( 2 );", ""); // Load help tab
map.bindCmd("keyboard", "l", "ShapeEdSelectWindow->tabBook.selectPage( 1 );", ""); // load Library Tab
map.bindCmd("keyboard", "j", "ShapeEdSelectWindow->tabBook.selectPage( 0 );", ""); // load scene object Tab
map.bindCmd("keyboard", "SPACE", "ShapeEdAnimWindow.togglePause();", "");
map.bindCmd("keyboard", "i", "ShapeEdSequences.onEditSeqInOut(\"in\", ShapeEdSeqSlider.getValue());", "");
map.bindCmd("keyboard", "o", "ShapeEdSequences.onEditSeqInOut(\"out\", ShapeEdSeqSlider.getValue());", "");
map.bindCmd("keyboard", "shift -", "ShapeEdSeqSlider.setValue(ShapeEdAnimWindow-->seqIn.getText());", "");
map.bindCmd("keyboard", "shift =", "ShapeEdSeqSlider.setValue(ShapeEdAnimWindow-->seqOut.getText());", "");
map.bindCmd("keyboard", "=", "ShapeEdAnimWindow-->stepFwdBtn.performClick();", "");
map.bindCmd("keyboard", "-", "ShapeEdAnimWindow-->stepBkwdBtn.performClick();", "");
this.map = map;
this.initSettings();
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:28,代码来源:ShapeEditorPlugin.cs
示例12: initialize
public static void initialize()
{
#region GameTSCtrl (HudlessPlayGui) oc_Newobject1
ObjectCreator oc_Newobject1 = new ObjectCreator("GameTSCtrl", "HudlessPlayGui", typeof (hudlessGui));
oc_Newobject1["canSaveDynamicFields"] = "1";
oc_Newobject1["isContainer"] = "1";
oc_Newobject1["Profile"] = "GuiContentProfile";
oc_Newobject1["HorizSizing"] = "right";
oc_Newobject1["VertSizing"] = "bottom";
oc_Newobject1["position"] = "0 0";
oc_Newobject1["Extent"] = "1024 768";
oc_Newobject1["MinExtent"] = "8 8";
oc_Newobject1["canSave"] = "1";
oc_Newobject1["Visible"] = "1";
oc_Newobject1["tooltipprofile"] = "GuiToolTipProfile";
oc_Newobject1["hovertime"] = "1000";
oc_Newobject1["Margin"] = "0 0 0 0";
oc_Newobject1["Padding"] = "0 0 0 0";
oc_Newobject1["AnchorTop"] = "1";
oc_Newobject1["AnchorBottom"] = "0";
oc_Newobject1["AnchorLeft"] = "1";
oc_Newobject1["AnchorRight"] = "0";
oc_Newobject1["cameraZRot"] = "0";
oc_Newobject1["forceFOV"] = "0";
oc_Newobject1["Enabled"] = "1";
oc_Newobject1["helpTag"] = "0";
oc_Newobject1["noCursor"] = "1";
#endregion
oc_Newobject1.Create();
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:33,代码来源:hudlessGui.gui.cs
示例13: onRightMouseUp
public override void onRightMouseUp(GuiControl ctrl)
{
int fontColorPos, backgroundColorPos, fillColorPos, fontSizePos, lockPos, winSettingsPos, setTitlePos, bitmapPos;
GuiCanvas Canvas = "Canvas";
ObjectCreator popupCreator = new ObjectCreator("PopupMenu", "", typeof (MenuBuilder));
popupCreator["isPopup"] = true.AsString();
popupCreator["object"] = "-1";
MenuBuilder popup = popupCreator.Create();
popup.removeAllItems();
popup["object"] = ctrl;
if (ctrl.getName() != "")
popup.appendItem(ctrl.getName() + '\t' + "" + '\t' + "");
else
popup.appendItem(ctrl.getClassName() + '\t' + "" + '\t' + "");
popup.enableItem(0, false);
if (ctrl.lockControl)
{
lockPos = popup.appendItem("Locked" + '\t' + "" + '\t' + ctrl + ".setControlLock(!" + ctrl + ".getControlLock());");
popup.checkItem(lockPos, ctrl.getControlLock());
}
if (ctrl.contextFontColor)
fontColorPos = popup.appendItem("Font Color..." + '\t' + "" + '\t' + "getColorI(\"" + ctrl.controlFontColor.AsString() + "\", \"" + ctrl + ".setControlFontColor\", " + ctrl.getRoot() + ", \"" + ctrl + ".setControlFontColor\", \"" + ctrl + ".setControlFontColor\" );");
if (ctrl.contextBackColor)
backgroundColorPos = popup.appendItem("Background Color..." + '\t' + "" + '\t' + "IngameContext.transparentCheck(" + ctrl + ", \"backColor\");");
if (ctrl.contextFillColor)
fillColorPos = popup.appendItem("Fill Color..." + '\t' + "" + '\t' + "IngameContext.transparentCheck(" + ctrl + ", \"fillColor\");");
if (ctrl.contextFontSize)
fontSizePos = popup.appendItem("Font Size..." + '\t' + "" + '\t' + "ChangeFontSize.loadDialog(" + ctrl + ");");
if (ctrl.windowSettings)
winSettingsPos = popup.appendItem("Window Settings" + '\t' + "" + '\t' + "WindowSettings.loadDialog(" + ctrl + ");");
if (ctrl.isMemberOfClass("GuiBitmapCtrl"))
{
if (((GuiControl) popup["object"])["setBitmap"].AsBool())
bitmapPos = popup.appendItem("Set Bitmap..." + '\t' + "" + '\t' + "getLoadFilename( \"All Image Files|*.png;*.jpeg;*.jpg;*.tga;*.jng;*.mng;*.gif;*.bmp;*.dds|png|*.png|jpeg|*.jpeg|jpg|*.jpg|tga|*.tga|jng|*.jng|mng|*.mng|gif|*.gif|bmp|*.bmp|dds|*.dds\"," + ctrl + "\".setBitmap\", \"\" );");
}
if (ctrl.isMemberOfClass("GuiWindowCtrl"))
{
if (((GuiControl) popup["object"])["setTitle"].AsBool())
setTitlePos = popup.appendItem("Set Title..." + '\t' + "" + '\t' + "SetTitle.loadDialog(" + ctrl + ");");
}
popup.showPopup(Canvas);
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:58,代码来源:InGameContext.cs
示例14: initializeInGameEditor
public static void initializeInGameEditor()
{
Omni.self.Print(" % - Initializing In-game GUI Editor");
SetTitle.initialize();
WindowSettings.initialize();
ChangeFontSize.initialize();
ObjectCreator oIngameContext = new ObjectCreator("GuiControl", "IngameContext, IngameGuiGroup", typeof (InGameContext));
oIngameContext.Create();
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:9,代码来源:main.cs
示例15: constructRSSHeadlineCollection
public static string constructRSSHeadlineCollection()
{
RSSHeadlineCollection ret = new ObjectCreator("ScriptObject", "", typeof (RSSHeadlineCollection)).Create();
// Create sim group for it
ret._simGroup = new ObjectCreator("SimGroup").Create().AsString();
return ret;
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:9,代码来源:RSSStructs.ed.cs
示例16: constructRSSHeadline
public static string constructRSSHeadline(string headline, string link)
{
ObjectCreator oc = new ObjectCreator("ScriptObject", "", typeof (RSSHeadline));
oc["_headline"] = headline;
oc["_link"] = link;
RSSHeadline ret = oc.Create();
return ret;
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:10,代码来源:RSSStructs.ed.cs
示例17: intialize
public static void intialize()
{
//-----------------------------------------------------------------------------
// Anim flag settings - must match material.h
// These cannot be enumed through script becuase it cannot
// handle the "|" operation for combining them together
// ie. Scroll | Wave does not work.
//-----------------------------------------------------------------------------
omni.iGlobal["$scroll"] = 1;
omni.iGlobal["$rotate"] = 2;
omni.iGlobal["$wave"] = 4;
omni.iGlobal["$scale"] = 8;
omni.iGlobal["$sequence"] = 16;
// Common stateblock definitions
ObjectCreator oc = new ObjectCreator("GFXSamplerStateData", "SamplerClampLinear");
oc["textureColorOp"] = "GFXTOPModulate";
oc["addressModeU"] = "GFXAddressClamp";
oc["addressModeV"] = "GFXAddressClamp";
oc["addressModeW"] = "GFXAddressClamp";
oc["magFilter"] = "GFXTextureFilterLinear";
oc["minFilter"] = "GFXTextureFilterLinear";
oc["mipFilter"] = "GFXTextureFilterLinear";
oc.Create();
oc = new ObjectCreator("GFXSamplerStateData", "SamplerClampPoint");
oc["textureColorOp"] = "GFXTOPModulate";
oc["addressModeU"] = "GFXAddressClamp";
oc["addressModeV"] = "GFXAddressClamp";
oc["addressModeW"] = "GFXAddressClamp";
oc["magFilter"] = "GFXTextureFilterPoint";
oc["minFilter"] = "GFXTextureFilterPoint";
oc["mipFilter"] = "GFXTextureFilterPoint";
oc.Create();
oc = new ObjectCreator("GFXSamplerStateData", "SamplerWrapLinear");
oc["textureColorOp"] = "GFXTOPModulate";
oc["addressModeU"] = "GFXTextureAddressWrap";
oc["addressModeV"] = "GFXTextureAddressWrap";
oc["addressModeW"] = "GFXTextureAddressWrap";
oc["magFilter"] = "GFXTextureFilterLinear";
oc["minFilter"] = "GFXTextureFilterLinear";
oc["mipFilter"] = "GFXTextureFilterLinear";
oc.Create();
oc = new ObjectCreator("GFXSamplerStateData", "SamplerWrapPoint");
oc["textureColorOp"] = "GFXTOPModulate";
oc["addressModeU"] = "GFXTextureAddressWrap";
oc["addressModeV"] = "GFXTextureAddressWrap";
oc["addressModeW"] = "GFXTextureAddressWrap";
oc["magFilter"] = "GFXTextureFilterPoint";
oc["minFilter"] = "GFXTextureFilterPoint";
oc["mipFilter"] = "GFXTextureFilterPoint";
oc.Create();
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:55,代码来源:commonMaterialData.cs
示例18: initialize
public static void initialize()
{
ObjectCreator tch = new ObjectCreator("ShaderData", "BlurDepthShader");
tch["DXVertexShaderFile"] = "shaders/common/lighting/shadowMap/boxFilterV.hlsl";
tch["DXPixelShaderFile"] = "shaders/common/lighting/shadowMap/boxFilterP.hlsl";
tch["OGLVertexShaderFile"] = "shaders/common/lighting/shadowMap/gl/boxFilterV.glsl";
tch["OGLPixelShaderFile"] = "shaders/common/lighting/shadowMap/gl/boxFilterP.glsl";
tch["pixVersion"] = 2.0;
tch.Create();
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:11,代码来源:init.cs
示例19: create
public string create(string treeView)
{
omni.Util.pushInstantGroup();
ObjectCreator undoObject = new ObjectCreator("UndoScriptAction", "", typeof (UndoActionReparentObjects));
//undoObject["class"] = "UndoActionReparentObjects";
undoObject["numObjects"] = "0";
undoObject["treeView"] = treeView;
UndoActionReparentObjects action = undoObject.Create();
omni.Util.popInstantGroup();
return action;
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:12,代码来源:UndoActionReparentObjects.ed.cs
示例20: respawnTurret
public virtual SceneObject respawnTurret(SimDataBlock datablock, string classname, TransformF transform, string isstatic, string respawn)
{
ObjectCreator tch = new ObjectCreator(classname);
tch["datablock"] = datablock;
tch["static"] = isstatic;
tch["respawn"] = respawn;
SceneObject turret = tch.Create();
turret.setTransform(transform);
((SimGroup) "MissionGroup").add(turret);
return turret;
}
开发者ID:souxiaosou,项目名称:OmniEngine.Net,代码行数:13,代码来源:SimGroup.cs
注:本文中的WinterLeaf.Engine.Classes.View.Creators.ObjectCreator类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论