private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; switch (Length) { case LengthEnum.Short: m_actorMeshes = WResourceManager.LoadActorResource("Ladder 0"); break; case LengthEnum.Medium: m_actorMeshes = WResourceManager.LoadActorResource("Ladder 1"); break; case LengthEnum.Long: m_actorMeshes = WResourceManager.LoadActorResource("Ladder 2"); break; case LengthEnum.Very_Long: m_actorMeshes = WResourceManager.LoadActorResource("Ladder 3"); break; case LengthEnum.Very_Short: m_actorMeshes = WResourceManager.LoadActorResource("Ladder 4"); break; default: m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); break; } }
private void UpdateActorMeshFromNameProperty() { TStringPropertyValue stringProperty = m_namePropertyValueCache as TStringPropertyValue; if (stringProperty != null) { //m_actorMesh = WResourceManager.LoadActorByName((string)stringProperty.GetValue()); if (m_actorMesh != null) { // Create and set up some initial lighting options so character's aren't drawn super brightly // until we support actually loading room environment lighting and apply it (see below). var lightPos = new Vector4(250, 200, 250, 0); var mainLight = new JStudio.OpenGL.GXLight(lightPos, -lightPos.Normalized(), new Vector4(1, 0, 1, 1), new Vector4(1.075f, 0, 0, 0), new Vector4(1.075f, 0, 0, 0)); var secondaryLight = new JStudio.OpenGL.GXLight(lightPos, -lightPos.Normalized(), new Vector4(0, 0, 1, 1), new Vector4(1.075f, 0, 0, 0), new Vector4(1.075f, 0, 0, 0)); Quaternion lightRot = Quaternion.FromAxisAngle(Vector3.UnitY, (float)Math.PI / 2f); Vector3 newLightPos = Vector3.Transform(new Vector3(-500, 0, 0), lightRot) + new Vector3(0, 50, 0); secondaryLight.Position = new Vector4(newLightPos, 0); m_actorMesh.SetHardwareLight(0, mainLight); m_actorMesh.SetHardwareLight(1, secondaryLight); m_actorMesh.SetTextureOverride("ZBtoonEX", "resources/textures/ZBtoonEX.png"); m_actorMesh.SetTextureOverride("ZAtoon", "resources/textures/ZAtoon.png"); m_objRender = null; } } if (m_actorMesh == null) { m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new Vector4(1, 1, 1, 1)); } }
public override void PostLoad() { base.PostLoad(); string model_path = "resources/models/foliage/bush.obj"; m_objRender = WResourceManager.LoadObjResource(model_path, new OpenTK.Vector4(1, 1, 1, 1), true, false, TextureWrapMode.MirroredRepeat); }
public override void PostLoad() { Transform.LocalScale = new Vector3(Transform.LocalScale.X, Transform.LocalScale.Y, Transform.LocalScale.X); m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCylinder.obj", new OpenTK.Vector4(1f, 1f, 0f, 1f), true); m_MessageReference = new MessageReference((ushort)MessageID); }
public override void PostLoad() { base.PostLoad(); m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorSphere_Trigger.obj", new OpenTK.Vector4(1f, 0.7f, 0.4f, 1f), true, false); VisualScaleMultiplier = new Vector3(1.5f, 1.5f, 1.5f); UpdateModel(); }
public override void PostLoad() { m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorCylinder.obj", new Vector4(1f, 1f, 0f, 1f), true, false); m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new Vector4(1f, 1f, 0f, 1f)); m_MessageReference = new MessageReference((ushort)MessageID); }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; switch (Type) { case TypeEnum.Raft: m_actorMeshes = WResourceManager.LoadActorResource("Raft"); break; case TypeEnum.Beedles_Shop_Ship: m_actorMeshes = WResourceManager.LoadActorResource("Beedle's Shop Ship"); break; case TypeEnum.Submarine: m_actorMeshes = WResourceManager.LoadActorResource("Submarine"); break; case TypeEnum.Beedles_Special_Shop_Ship: m_actorMeshes = WResourceManager.LoadActorResource("Beedle's Special Shop Ship"); break; case TypeEnum.Salvage_Corp_Ship: m_actorMeshes = WResourceManager.LoadActorResource("Salvage Corp Ship"); break; default: m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); break; } }
public void UpdateModel() { m_brazierModel = null; m_objRender = null; m_actorMeshes = null; if (HasBrazier()) { if (IsWooden) { m_actorMeshes = WResourceManager.LoadActorResource("Wooden Torch"); } else { m_actorMeshes = WResourceManager.LoadActorResource("Golden Torch"); } } if (m_actorMeshes == null) { m_actorMeshes = new List <J3D>(); } if (m_actorMeshes.Count > 0) { m_brazierModel = m_actorMeshes[0]; } else { m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1, 1, 1, 1)); } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; switch (BehaviorType) { case BehaviorTypeEnum.Shoots_Fireballs: m_actorMeshes = WResourceManager.LoadActorResource("Fireball-Shooting Wizzrobe"); break; case BehaviorTypeEnum.Spawns_Enemies_and_Shoots_Fireballs: m_actorMeshes = WResourceManager.LoadActorResource("Spawner Wizzrobe"); break; case BehaviorTypeEnum.Miniboss: m_actorMeshes = WResourceManager.LoadActorResource("Mini-boss Wizzrobe"); break; case BehaviorTypeEnum.Shoots_Fireballs_Alt_Color: m_actorMeshes = WResourceManager.LoadActorResource("Alt Color Fireball Wizzrobe"); break; default: m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); break; } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; switch (Type) { case TypeEnum.Small_Rock: m_actorMeshes = WResourceManager.LoadActorResource("Small Rock"); break; case TypeEnum.Small_Black_Rock: m_actorMeshes = WResourceManager.LoadActorResource("Small Black Rock"); break; case TypeEnum.Boulder: m_actorMeshes = WResourceManager.LoadActorResource("Boulder"); break; case TypeEnum.Head_Boulder: m_actorMeshes = WResourceManager.LoadActorResource("Head Boulder"); break; case TypeEnum.Small_Boulder: m_actorMeshes = WResourceManager.LoadActorResource("Small Boulder"); break; default: m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); break; } }
public override void PostLoad() { base.PostLoad(); m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f), true, false); MessageReference = new MessageReference((ushort)MessageID); }
public override void OnConstruction() { base.OnConstruction(); ColorOverrides = new TevColorOverride(); m_actorMeshes = new List <J3D>(); PropertyChanged += VisibleDOMNode_PropertyChanged; IsRendered = true; m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1, 1, 1, 1)); }
private void UpdateModel() { WDOMNode cur_object = this; while (cur_object.Parent != null) { cur_object = cur_object.Parent; } WRoom currRoom = cur_object as WRoom; string currStageName = World.Map.MapName; string model_path; switch (Type) { case TypeEnum.Grass: if (currStageName.StartsWith("kin") || currStageName == "Xboss1") { // Forbidden Woods grass model_path = "resources/models/foliage/grass_Vmori.obj"; } else { model_path = "resources/models/foliage/grass.obj"; } break; case TypeEnum.Tree: model_path = "resources/models/foliage/tree.obj"; break; case TypeEnum.White_Flower: model_path = "resources/models/foliage/flower.obj"; break; case TypeEnum.Pink_Flower: if (currStageName == "sea" && currRoom.RoomIndex == 33) { // Private Oasis flowers model_path = "resources/models/foliage/pflower_oasis.obj"; } else { model_path = "resources/models/foliage/pflower_pink.obj"; } break; default: model_path = "resources/editor/EditorCube.obj"; break; } m_objRender = WResourceManager.LoadObjResource(model_path, new OpenTK.Vector4(1, 1, 1, 1), true, false, TextureWrapMode.MirroredRepeat); }
public override void PostLoad() { m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new Vector4(0.5f, 0.75f, 1f, 1f)); if (Name == "AttTag") { m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorCylinder.obj", new Vector4(0.5f, 0.75f, 1f, 1f), true, false); } else if (Name == "AttTagB") { m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorCylinder.obj", new Vector4(0.5f, 0.75f, 1f, 1f), true, false); } }
private void UpdateModel() { switch (CollisionArchive) { case CollisionArchiveEnum.Akabe: m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorVerticalPlaneBottomOrigin.obj", new OpenTK.Vector4(1, 1, 1, 1), true, false); VisualScaleMultiplier = new Vector3(1f, 1f, 1f); break; case CollisionArchiveEnum.AkabeD: m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorVerticalPlaneBottomOrigin.obj", new OpenTK.Vector4(1, 1, 1, 1), true, false); VisualScaleMultiplier = new Vector3(10f, 10f, 1f); break; case CollisionArchiveEnum.AkabeK: m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorVerticalPlaneBottomOrigin.obj", new OpenTK.Vector4(1, 1, 1, 1), true, false); VisualScaleMultiplier = new Vector3(1f, 1f, 1f); break; case CollisionArchiveEnum.NBOX: m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorCubeBottomOrigin.obj", new OpenTK.Vector4(1, 1, 1, 1), true, false); VisualScaleMultiplier = new Vector3(10f, 10f, 10f); break; default: m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorVerticalPlaneBottomOrigin.obj", new OpenTK.Vector4(1, 1, 1, 1), true, false); VisualScaleMultiplier = new Vector3(1f, 1f, 1f); break; } switch (ScaleMode) { case ScaleModeEnum.Akabe: VisualScaleMultiplier = new Vector3(1f, 1f, 1f); break; case ScaleModeEnum.Akabe10: VisualScaleMultiplier = new Vector3(10f, 10f, 1f); break; case ScaleModeEnum.NBOX: VisualScaleMultiplier = new Vector3(1f, 1f, 1f); break; case ScaleModeEnum.NBOX10: VisualScaleMultiplier = new Vector3(10f, 10f, 10f); break; default: VisualScaleMultiplier = new Vector3(1f, 1f, 1f); break; } }
private void UpdateModel() { m_actorMeshes = GetModelsFromStageDir(); if (m_actorMeshes.Count == 0) { m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); } else { m_objRender = null; } }
public override void PostLoad() { if (Name == "AttTag") { Transform.LocalScale = new Vector3(Transform.LocalScale.X, Transform.LocalScale.Y, Transform.LocalScale.X); m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCylinder.obj", new OpenTK.Vector4(0.5f, 0.75f, 1f, 1f), true); } else if (Name == "AttTagB") { Transform.LocalScale = new Vector3(Transform.LocalScale.X, Transform.LocalScale.Y, Transform.LocalScale.X); m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCylinder.obj", new OpenTK.Vector4(0.5f, 0.75f, 1f, 1f), true); } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; switch (Type) { case TypeEnum.Breakable_Wooden_Crate: case TypeEnum.Unbreakable_Wooden_Crate_A: case TypeEnum.Unbreakable_Wooden_Crate_B: case TypeEnum.Unbreakable_Wooden_Crate_C: m_actorMeshes = WResourceManager.LoadActorResource("Wooden Crate"); break; case TypeEnum.Black_Box_A: case TypeEnum.Black_Box_B: m_actorMeshes = WResourceManager.LoadActorResource("Black Box"); break; case TypeEnum.Black_Box_With_Statue_on_Top: m_actorMeshes = WResourceManager.LoadActorResource("Black Box With Statue on Top"); break; case TypeEnum.Big_Black_Box: m_actorMeshes = WResourceManager.LoadActorResource("Big Black Box"); break; case TypeEnum.Golden_Crate: m_actorMeshes = WResourceManager.LoadActorResource("Golden Crate"); break; case TypeEnum.Metal_Box: m_actorMeshes = WResourceManager.LoadActorResource("Pushable Metal Box"); break; case TypeEnum.Metal_Box_With_Spring: m_actorMeshes = WResourceManager.LoadActorResource("Pushable Metal Box With Spring"); break; case TypeEnum.Mirror: m_actorMeshes = WResourceManager.LoadActorResource("Mirror"); break; case TypeEnum.Mossy_Black_Box: m_actorMeshes = WResourceManager.LoadActorResource("Mossy Black Box"); break; default: m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); break; } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; if (ShowWindEmblemModel) { m_actorMeshes = WResourceManager.LoadActorResource("Wind Crest"); } else { m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); } }
private void UpdateModel() { // Note: Not sure if all of the types are cylinders. m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorCylinder.obj", new Vector4(1f, 1f, 1f, 1f), true, false); if (Type == TypeEnum.agbCSW) { VisualScaleMultiplier = new Vector3(8000f / 50f, 8000f / 50f, 8000f / 50f); } else { VisualScaleMultiplier = new Vector3(200f / 50f, 200f / 50f, 200f / 50f); } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; if (Name == "Ko1") { switch (ZillType) { case ZillTypeEnum.Chasing_Zill: case ZillTypeEnum.Unknown_1: case ZillTypeEnum.Standing_Zill: m_actorMeshes = WResourceManager.LoadActorResource("Zill"); break; case ZillTypeEnum.Sleeping_Zill: m_actorMeshes = WResourceManager.LoadActorResource("Sleeping Zill"); break; default: m_actorMeshes = WResourceManager.LoadActorResource("Zill"); break; } } else if (Name == "Ko2") { switch (JoelType) { case JoelTypeEnum.Joel_with_Stick: m_actorMeshes = WResourceManager.LoadActorResource("Joel with Stick"); break; case JoelTypeEnum.Standing_Joel: m_actorMeshes = WResourceManager.LoadActorResource("Joel"); break; case JoelTypeEnum.Sleeping_Joel: m_actorMeshes = WResourceManager.LoadActorResource("Sleeping Joel"); break; default: m_actorMeshes = WResourceManager.LoadActorResource("Joel"); break; } } else { m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; var models = WResourceManager.LoadModelForItem(ItemID); if (models == null) { m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); } else { m_actorMeshes = models; } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; switch (Type) { case TypeEnum.Mothula: if (MothulaType == MothulaTypeEnum.Wingless_Mothula) { m_actorMeshes = WResourceManager.LoadActorResource("Wingless Mothula"); } else { m_actorMeshes = WResourceManager.LoadActorResource("Winged Mothula"); } break; case TypeEnum.Wing_that_falls_down_spinning: case TypeEnum.Wing_that_floats_down_gently: switch (WhichWing) { case WhichWingEnum.Lower_Right_Wing: m_actorMeshes = WResourceManager.LoadActorResource("Mothula Lower Right Wing"); break; case WhichWingEnum.Lower_Left_Wing: m_actorMeshes = WResourceManager.LoadActorResource("Mothula Lower Left Wing"); break; case WhichWingEnum.Upper_Right_Wing: m_actorMeshes = WResourceManager.LoadActorResource("Mothula Upper Right Wing"); break; case WhichWingEnum.Upper_Left_Wing: m_actorMeshes = WResourceManager.LoadActorResource("Mothula Upper Left Wing"); break; default: m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); break; } break; default: m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); break; } }
private void UpdateModel() { switch (Type) { case TypeEnum.Water_Splashes: m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorCylinder.obj", new OpenTK.Vector4(0.5f, 1f, 1f, 1f), true, false); VisualScaleMultiplier = new Vector3(5f, 10f, 5f); break; // TODO default: m_RegionAreaModel = WResourceManager.LoadObjResource("resources/editor/EditorCylinder.obj", new OpenTK.Vector4(0.5f, 1f, 1f, 1f), true, false); VisualScaleMultiplier = new Vector3(5f, 10f, 5f); break; } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; if (Name == "Ym1") { m_actorMeshes = WResourceManager.LoadActorResource("Mesa"); } else if (Name == "Ym2") { m_actorMeshes = WResourceManager.LoadActorResource("Abe"); } else { m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); } }
private void UpdateModel() { switch (Type) { case FoliageType.White_Flower: m_objRender = WResourceManager.LoadObjResource("resources/models/flowers/flower.obj", new OpenTK.Vector4(1, 1, 1, 1)); break; case FoliageType.Pink_Flower: m_objRender = WResourceManager.LoadObjResource("resources/models/flowers/pflower_pink.obj", new OpenTK.Vector4(1, 1, 1, 1)); break; case FoliageType.Grass: case FoliageType.Tree: m_objRender = WResourceManager.LoadObjResource("resources/models/flowers/pflower_pink.obj", new OpenTK.Vector4(1, 1, 1, 1)); break; } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; List <JStudio.J3D.J3D> models = null; if ((int)SpawnedItem <= 0x1F) { models = WResourceManager.LoadModelForItem((ItemID)SpawnedItem); } if (models == null) { m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); } else { m_actorMeshes = models; } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; switch (Type) { case TypeEnum.Short_Ice_Platform: m_actorMeshes = WResourceManager.LoadActorResource("Short Ice Platform"); break; case TypeEnum.Tall_Ice_Platform: m_actorMeshes = WResourceManager.LoadActorResource("Tall Ice Platform"); break; default: m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); break; } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; switch (Model) { case ModelEnum.Large_Shutter: m_actorMeshes = WResourceManager.LoadActorResource("Large Shutter"); break; case ModelEnum.Small_Shutter: m_actorMeshes = WResourceManager.LoadActorResource("Small Shutter"); break; default: m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); break; } }
private void UpdateModel() { m_actorMeshes.Clear(); m_objRender = null; VisualScaleMultiplier = Vector3.One; if (Type == TypeEnum.Light_Beam) { VisualScaleMultiplier = new Vector3(1f, 2f, 1f); if (Unknown_4 >= 9) { m_actorMeshes = WResourceManager.LoadActorResource("Light Ray Cylinder"); } else { m_actorMeshes = WResourceManager.LoadActorResource("Light Ray Cone"); } } else { m_objRender = WResourceManager.LoadObjResource("resources/editor/EditorCube.obj", new OpenTK.Vector4(1f, 1f, 1f, 1f)); } }