
PluginHeader{
	RailSimVersion = 2.00;
	PluginType = Train;
	PluginName = "大阪市交通局 新30系 谷町線 冷改アルミ編成 付随車";
	PluginAuthor = "n";
	IconTexture = "icon.png";
}
TrainInfo{
	FrontLimit = 9.35;
	TailLimit = -9.35;
	MaxVelocity = 70.0;
	MaxAcceleration = 2.5;
	MaxDeceleration = 3.5;
	DoorClosingTime = 5.0;
}
DefineSwitch "■基本設定"{
}
DefineSwitch "電源"{
GroupCommon = "nomtbn30tra電源";
	Entry = "入";
	Entry = "切";
}
DefineSwitch "■灯火類設定-"{
}
DefineSwitch "幕灯"{
GroupCommon = "nomtbn30tra幕灯";
	Entry = "入";
	Entry = "切";
}
DefineSwitch "客室照明"{
GroupCommon = "nomtbn30tra客室灯";
	Entry = "入";
	Entry = "切";
}
DefineSwitch "■列車設定"{
}
DefineSwitch "行先(往)"{
GroupCommon = "nomtbn30tra行先往";
	Entry = "無表示";
	Entry = "大日";
	Entry = "八尾南";
	Entry = "守口";
	Entry = "文の里";
	Entry = "都島";
	Entry = "喜連瓜破";
	Entry = "長原";
	Entry = "";
	Entry = "";
	Entry = "";
	Entry = "";
	Entry = "回送";
	Entry = "試運転";
	Entry = "臨時";
}
DefineSwitch "行先(復)"{
GroupCommon = "nomtbn30tra行先復";
	Entry = "無表示";
	Entry = "大日";
	Entry = "八尾南";
	Entry = "守口";
	Entry = "文の里";
	Entry = "都島";
	Entry = "喜連瓜破";
	Entry = "長原";
	Entry = "";
	Entry = "";
	Entry = "";
	Entry = "";
	Entry = "回送";
	Entry = "試運転";
	Entry = "臨時";
}
DefineSwitch "■車両設定"{
}
DefineSwitch "編成"{
GroupCommon = "nomtbn30tra編成";
	Entry = "44";
	Entry = "45";
	Entry = "46";
	Entry = "47";
	Entry = "48";
	Entry = "49";
}
DefineSwitch "号車"{
	Entry = "3号車";
	Entry = "4号車";
}
DefineSwitch "■質感設定"{
}
DefineSwitch "簡易影"{
	GroupCommon = "nomtbn30tra簡易陰";
	Entry = "入";
	Entry = "切";
}
DefineSwitch "PBR"{
	GroupCommon = "nomtbn30traPBR";
	Entry = "使用しません";
	Entry = "";
}
DefineSwitch "車体明るさ(PBR有効時のみ)"{
	GroupCommon = "nomtbn30tra車体明るさ(PBR有効時のみ)";
	Entry = "使用しません";
	Entry = "";
	Entry = "";
	Entry = "";
	Entry = "";
	Entry = "";
	Entry = "";
	Entry = "";
	Entry = "";
	Entry = "";
}
PrimaryAssembly{
	Axle "wheel1"{
		ModelFileName = "../n_omtbn30_tra_1/wheel_t.x";
		CastShadow = no;
		AlphaZeroTest = 0,1;
		Diameter = 0.762;
		Symmetric = 16;
		Coord = (6.8,0.381);
	}
	Axle "wheel2"{
		ModelFileName = "../n_omtbn30_tra_1/wheel_t.x";
		CastShadow = no;
		AlphaZeroTest = 0,1;
		Diameter = 0.762;
		Symmetric = 16;
		Coord = (4.7,0.381);
	}
	Axle "wheel3"{
		ModelFileName = "../n_omtbn30_tra_1/wheel_t.x";
		CastShadow = no;
		AlphaZeroTest = 0,1;
		Diameter = 0.762;
		Symmetric = 16;
		Coord = (-6.8,0.381);
	}
	Axle "wheel4"{
		ModelFileName = "../n_omtbn30_tra_1/wheel_t.x";
		CastShadow = no;
		AlphaZeroTest = 0,1;
		Diameter = 0.762;
		Symmetric = 16;
		Coord = (-4.7,0.381);
	}
	Body "Bogie1"{
		ModelFileName = "../n_omtbn30_tra_1/bogie_t.x";
		JointZY "wheel1"{
			AttachCoord = (0,0);
			LocalCoord = (1.05, 0.0);
		}
		JointZY "wheel2"{
			AttachCoord = (0,0);
			LocalCoord = (-1.05, 0.0);
		}
	}
	Body "Bogie2"{
		ModelFileName = "../n_omtbn30_tra_1/bogie_t.x";
		Turn = yes;
		JointZY "wheel3"{
			AttachCoord = (0.0,0.0);
			LocalCoord = (1.05, 0.0);
		}
		JointZY "wheel4"{
			AttachCoord = (0,0);
			LocalCoord = (-1.05, 0.0);
		}
	}
	Body "Dummy"{
		ModelFileName = "";
		JointZY "Bogie1"{
			AttachCoord = (0.0, 0.619);
			LocalCoord = (5.75, 1.0);
		}
		JointZY "Bogie2"{
			AttachCoord = (0.0, 0.619);
			LocalCoord = (-5.75, 1.0);
		}
	}
	Object3D "MainBody"{
		ModelFileName = "../n_omtbn30_tra_1/body_3144.x";
		ChangeAlpha = 25, 0.0;
		Transparent = 14,15,16;
		NoCastShadow = 18,19,20,21,25;
		If "電源"==0{
			If "幕灯"==0{
					ChangeMaterial{
						MaterialID = 2;
						Emissive = 1.0, 1.0, 1.0;
　　　　　	　　		}
			}
			If "客室照明"==0{
					ChangeMaterial{
						MaterialID = 5,6,7;
						Emissive = 1.0, 1.0, 1.0;
　　　　　	　　		}
			}
		}
		If( !"_FRONT" && "号車"!=3 )||( "_FRONT" && "号車"==3 ){
			If "PBR" ==0{
				ApplySwitch "行先(往)"{
					Case 1:
		
					Case 2:
						ShiftTexture = 2, 0.0, 0.03125;
					Case 3:
						ShiftTexture = 2, 0.0, 0.0625;
					Case 4:
						ShiftTexture = 2, 0.0, 0.09375;
					Case 5:
						ShiftTexture = 2, 0.0, 0.125;
					Case 6:
						ShiftTexture = 2, 0.0, 0.15625;
					Case 7:
						ShiftTexture = 2, 0.0, 0.1875;
					Case 12:
						ShiftTexture = 2, 0.0625, 0.15625;
					Case 13:
						ShiftTexture = 2, 0.0625, 0.1875;
					Case 14:
						ShiftTexture = 2, 0.0625, 0.21875;
					Default:
						ShiftTexture = 2, 0.0, 0.21875;
				}
			}Else{
				ApplySwitch "行先(往)"{
					Case 1:
						ShiftTexture = 2, 0.0, 0.25;
					Case 2:
						ShiftTexture = 2, 0.0, 0.28125;
					Case 3:
						ShiftTexture = 2, 0.0, 0.3125;
					Case 4:
						ShiftTexture = 2, 0.0, 0.34375;
					Case 5:
						ShiftTexture = 2, 0.0, 0.375;
					Case 6:
						ShiftTexture = 2, 0.0, 0.40625;
					Case 7:
						ShiftTexture = 2, 0.0625, 0.25;
					Case 8:
						ShiftTexture = 2, 0.0625, 0.28125;
					Case 9:
						ShiftTexture = 2, 0.0625, 0.3125;
					Case 10:
						ShiftTexture = 2, 0.0625, 0.34375;
					Case 11:
						ShiftTexture = 2, 0.0625, 0.375;
					Case 12:
						ShiftTexture = 2, 0.0625, 0.40625;
					Case 13:
						ShiftTexture = 2, 0.0625, 0.4375;
					Case 14:
						ShiftTexture = 2, 0.0625, 0.46875;
					Default:
						ShiftTexture = 2, 0.0, 0.21875;
				}
			}
		}Else{
			If "PBR" ==0{
				ApplySwitch "行先(復)"{
					Case 1:
		
					Case 2:
						ShiftTexture = 2, 0.0, 0.03125;
					Case 3:
						ShiftTexture = 2, 0.0, 0.0625;
					Case 4:
						ShiftTexture = 2, 0.0, 0.09375;
					Case 5:
						ShiftTexture = 2, 0.0, 0.125;
					Case 6:
						ShiftTexture = 2, 0.0, 0.15625;
					Case 7:
						ShiftTexture = 2, 0.0, 0.1875;
					Case 12:
						ShiftTexture = 2, 0.0625, 0.15625;
					Case 13:
						ShiftTexture = 2, 0.0625, 0.1875;
					Case 14:
						ShiftTexture = 2, 0.0625, 0.21875;
					Default:
						ShiftTexture = 2, 0.0, 0.21875;
				}
			}Else{
				ApplySwitch "行先(復)"{
					Case 1:
						ShiftTexture = 2, 0.0, 0.25;
					Case 2:
						ShiftTexture = 2, 0.0, 0.28125;
					Case 3:
						ShiftTexture = 2, 0.0, 0.3125;
					Case 4:
						ShiftTexture = 2, 0.0, 0.34375;
					Case 5:
						ShiftTexture = 2, 0.0, 0.375;
					Case 6:
						ShiftTexture = 2, 0.0, 0.40625;
					Case 7:
						ShiftTexture = 2, 0.0625, 0.25;
					Case 8:
						ShiftTexture = 2, 0.0625, 0.28125;
					Case 9:
						ShiftTexture = 2, 0.0625, 0.3125;
					Case 10:
						ShiftTexture = 2, 0.0625, 0.34375;
					Case 11:
						ShiftTexture = 2, 0.0625, 0.375;
					Case 12:
						ShiftTexture = 2, 0.0625, 0.40625;
					Case 13:
						ShiftTexture = 2, 0.0625, 0.4375;
					Case 14:
						ShiftTexture = 2, 0.0625, 0.46875;
					Default:
						ShiftTexture = 2, 0.0, 0.21875;
				}
			}
		}
		ApplySwitch "号車"{
			Case 0:
				If "PBR"==0{
					ChangeAlpha = 25, 1.0;
				}
				ShiftTexture = 19, 0.0, 0.046875;
			Case 1:
				ShiftTexture = 19, 0.0, 0.03125;
		}
		If "PBR"==1{
			ApplySwitch "車体明るさ(PBR有効時のみ)"{
				Case 0:
					ChangeModel = "../n_omtbn30_tra_1/body_3145.x", 1.0;
				Case 1,2:
					ChangeModel = "../n_omtbn30_tra_1/body_3111.x", 1.0;
				Case 3,4:
					ChangeModel = "../n_omtbn30_tra_1/body_3112.x", 1.0;
				Case 5:
					ChangeModel = "../n_omtbn30_tra_1/body_3135.x", 1.0;
				Case 6,7:
					ChangeModel = "", 1.0;
			}
		}
		If"PBR"==0||("PBR"==1&&("車体明るさ(PBR有効時のみ)"<2||"車体明るさ(PBR有効時のみ)"==3||"車体明るさ(PBR有効時のみ)"==5)){
			ApplySwitch "編成"{
				Case 0:
	
				Case 1:
					ShiftTexture = 18, 0.0, 0.015625;
				Case 2:
					ShiftTexture = 18, 0.0, 0.03125;
				Case 3:
					ShiftTexture = 18, 0.0, 0.046875;
				Case 4:
					ShiftTexture = 18, 0.0, 0.0625;
				Case 5:
					ShiftTexture = 18, 0.0, 0.078125;
			}
		}
		If "PBR"==1{
			If "車体明るさ(PBR有効時のみ)"==2||"車体明るさ(PBR有効時のみ)"==4{
				ApplySwitch "編成"{
					Case 0:
						ShiftTexture = 18, 0.0, 0.09375;
					Case 1:
						ShiftTexture = 18, 0.0, 0.109375;
					Case 2:
						ShiftTexture = 18, 0.03125, 0.09375;
					Case 3:
						ShiftTexture = 18, 0.03125, 0.109375;
					Default:
						ChangeAlpha = 18, 0.0;
				}
			}
			If "車体明るさ(PBR有効時のみ)"==6{
				ApplySwitch "編成"{
					Case 0:
		
					Case 1:
						ShiftTexture = 18, 0.0, 0.015625;
					Case 2:
						ShiftTexture = 18, 0.0, 0.046875;
					Case 3:
						ShiftTexture = 18, 0.0, 0.0625;
					Case 4:
						ShiftTexture = 18, 0.0, 0.078125;
					Case 5:
						ShiftTexture = 18, 0.0, 0.109375;
				}
			}
			If "車体明るさ(PBR有効時のみ)"==7{
				ApplySwitch "編成"{
					Case 0:
						ShiftTexture = 18, 0.03125, 0.09375;
					Case 1:
						ShiftTexture = 18, 0.03125, 0.109375;
					Default:
						ChangeAlpha = 18, 0.0;
				}
			}
		}
		Joint3D "Dummy"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "c"{
		ModelFileName = "../n_omtbn30_tra_1/yuka_c.x";
		Joint3D "Dummy"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "yuka"{
		ModelFileName = "../n_omtbn30_tra_1/yuka_3600.x";
		Joint3D "Dummy"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "Doorll"{
		ModelFileName = "../n_omtbn30_tra_1/Doorl.x";
		Transparent = 3;
		If "電源"==0 && "客室照明"==0{
				ChangeMaterial{
					MaterialID = 0;
					Emissive = 1.0, 1.0, 1.0;
				}
　　　　　　　　}
		If "_DOOR1"{
			StaticMove{
				Displacement = (0.0, 0.0, 0.6);
				PreAnimationDelay = 1.0;
				AnimationTime = 1.5;
				 PreReverseDelay = 0.5;
				ReverseTime = 1.5;
			}
			StaticMove{
				Displacement = (0.0, 0.0, 0.05);
				PreAnimationDelay = 2.5;
				AnimationTime = 0.5;
				 PreReverseDelay = 2.0;
				ReverseTime = 0.5;
			}
		}
		If "PBR"==1{
			If "車体明るさ(PBR有効時のみ)"==0{
				ChangeModel = "../n_omtbn30_tra_1/Doorl.x", 1.0;
				ShiftTexture = 1, 0.0, 0.4375;
			}
			ChangeModel = "../n_omtbn30_tra_1/doorl_1.x", 1.0;
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}

	Object3D "Doorlr"{
		ModelFileName = "../n_omtbn30_tra_1/Doorr.x";
		Transparent = 3;
		If "電源"==0 && "客室照明"==0{
				ChangeMaterial{
					MaterialID = 0;
					Emissive = 1.0, 1.0, 1.0;
				}
　　　　　　　　}
		If "_DOOR1" {
			StaticMove{
				Displacement = (0.0, 0.0, -0.6);
				PreAnimationDelay = 1.0;
				AnimationTime = 1.5;
				 PreReverseDelay = 0.5;
				ReverseTime = 1.5;
			}
			StaticMove{
				Displacement = (0.0, 0.0, -0.05);
				PreAnimationDelay = 2.5;
				AnimationTime = 0.5;
				 PreReverseDelay = 2.0;
				ReverseTime = 0.5;
			}
		}
		If "PBR"==1{
			If "車体明るさ(PBR有効時のみ)"==0{
				ChangeModel = "../n_omtbn30_tra_1/Doorr.x", 1.0;
				ShiftTexture = 1, 0.0, 0.4375;
			}
			ChangeModel = "../n_omtbn30_tra_1/doorr_1.x", 1.0;
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "Doorrl"{
		ModelFileName = "../n_omtbn30_tra_1/Doorr.x";
		Transparent = 3;
		If "電源"==0 && "客室照明"==0{
				ChangeMaterial{
					MaterialID = 0;
					Emissive = 1.0, 1.0, 1.0;
				}
　　　　　　　　}
		If "_DOOR2"{
			StaticMove{
				Displacement = (0.0, 0.0, -0.6);
				PreAnimationDelay = 1.0;
				AnimationTime = 1.5;
				 PreReverseDelay = 0.5;
				ReverseTime = 1.5;
			}
			StaticMove{
				Displacement = (0.0, 0.0, -0.05);
				PreAnimationDelay = 2.5;
				AnimationTime = 0.5;
				 PreReverseDelay = 2.0;
				ReverseTime = 0.5;
			}
		}
		If "PBR"==1{
			If "車体明るさ(PBR有効時のみ)"==0{
				ChangeModel = "../n_omtbn30_tra_1/Doorr.x", 1.0;
				ShiftTexture = 1, 0.0, 0.4375;
			}
			ChangeModel = "../n_omtbn30_tra_1/doorr_1.x", 1.0;
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
			AttachDir = (0.0, 0.0, -1.0);
		}
	}

	Object3D "Doorrr"{
		ModelFileName = "../n_omtbn30_tra_1/Doorl.x";
		Transparent = 3;
		If "電源"==0 && "客室照明"==0{
				ChangeMaterial{
					MaterialID = 0;
					Emissive = 1.0, 1.0, 1.0;
				}
　　　　　　　　}
		If "_DOOR2" {
			StaticMove{
				Displacement = (0.0, 0.0, 0.6);
				PreAnimationDelay = 1.0;
				AnimationTime = 1.5;
				 PreReverseDelay = 0.5;
				ReverseTime = 1.5;
			}
			StaticMove{
				Displacement = (0.0, 0.0, 0.05);
				PreAnimationDelay = 2.5;
				AnimationTime = 0.5;
				 PreReverseDelay = 2.0;
				ReverseTime = 0.5;
			}
		}
		If "PBR"==1{
			If "車体明るさ(PBR有効時のみ)"==0{
				ChangeModel = "../n_omtbn30_tra_1/Doorl.x", 1.0;
				ShiftTexture = 1, 0.0, 0.4375;
			}
			ChangeModel = "../n_omtbn30_tra_1/doorl_1.x", 1.0;
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
			AttachDir = (0.0, 0.0, -1.0);
		}
	}
	Object3D "tojime"{
		ModelFileName = "../n_omtbn30_tra_1/tojime_0.x";
		If "PBR"==0||"PBR"==1&&"車体明るさ(PBR有効時のみ)"==0{
			ChangeModel = "../n_omtbn30_tra_1/tojime_2.x", 1.0;
		}
		Joint3D "Dummy"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "Doorl"{
		ModelFileName = "../n_omtbn30_tra_1/tojime.x";
		StaticRotation{
			RotationAxis = (0.0, 1.0, 0.0);
			RotationAngle = 180;
		}
		If "PBR"==0||"PBR"==1&&"車体明るさ(PBR有効時のみ)"==0{
			StaticMove{
				Displacement = (-1.41, 3.31, 5.35);
			}
		}Else{
			StaticMove{
				Displacement = (-1.41, 3.175, -0.45);
			}
		}
		If "_DOOR2"{
			StaticRotation{
				RotationAxis = (0.0, 1.0, 0.0);
				RotationAngle = 180;
				PreAnimationDelay = 1.0;
				AnimationTime = 0.0;
				 PreReverseDelay = 2.5;
				ReverseTime = 0.0;
			}
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "Doorr"{
		ModelFileName = "../n_omtbn30_tra_1/tojime.x";
		If "PBR"==0||"PBR"==1&&"車体明るさ(PBR有効時のみ)"==0{
			StaticMove{
				Displacement = (-1.41, 3.31, 5.35);
			}
		}Else{
			StaticMove{
				Displacement = (-1.41, 3.175, 0.45);
			}
		}
		If "_DOOR1"{
			StaticRotation{
				RotationAxis = (0.0, 1.0, 0.0);
				RotationAngle = 180;
				PreAnimationDelay = 1.0;
				AnimationTime = 0.0;
				 PreReverseDelay = 2.5;
				ReverseTime = 0.0;
			}
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "Shadow"{
		ModelFileName = "";
		CastShadow = no;
		NoShadow = 0;
		If "簡易影" ==0 && !"_SHADOW"==1 {
			ChangeModel = "../n_omtbn30_tra_1/Shadow.x", 1.0;
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	FrontCabin{
		Joint3D "MainBody"{
			AttachCoord = (0.0,0.0,0.0);
		}
	}
}

