
PluginHeader{
	RailSimVersion = 2.00;
	PluginType = Train;
	PluginName = "帝都高速度交通営団 05系 6次車 先頭車";
	PluginAuthor = "n";
	IconTexture = "";
}
TrainInfo{
	FrontLimit = 10.27;
	TailLimit = -10.00;
	MaxVelocity = 110.0;
	MaxAcceleration = 3.54;
	MaxDeceleration = 3.5;
	DoorClosingTime = 5.0;
}
DefineSwitch "■基本設定"{
}
DefineSwitch "電源"{
GroupCommon = "n05-19電源";
	Entry = "入";
	Entry = "切";
}
DefineSwitch "パンタ高さ"{
	GroupCommon = "n05-19pt";
	Entry = "自動(基準：シンプルカテナリ)";
	Entry = "剛体架線";
}
DefineSwitch "■灯火類設定-"{
}
DefineSwitch "前照灯"{
GroupCommon = "n05-19前照灯";
	Entry = "自動";
	Entry = "入";
	Entry = "切";
}
DefineSwitch "尾灯"{
GroupCommon = "n05-19尾灯";
	Entry = "自動";
	Entry = "入(入替)";
	Entry = "切";
}
DefineSwitch "運転室灯"{
GroupCommon = "n05-19運転室灯";
	Entry = "自動";
	Entry = "入";
	Entry = "切";
}
DefineSwitch "客室照明"{
GroupCommon = "n05-19客室灯";
	Entry = "入";
	Entry = "切";
}
DefineSwitch "■列車設定"{
}
DefineSwitch "行先"{
GroupCommon = "n05-19行先";
	Entry = "無表示";
	Entry = "回送";
	Entry = "西船橋";
	Entry = "中野";
	Entry = "三鷹";
	Entry = "快速　東葉勝田台";
	Entry = "快速　中野";
	Entry = "津田沼";
}
DefineSwitch "列車番号100位"{
GroupCommon = "n05-19列車番号100位";
	Entry = "0";
	Entry = "1";
	Entry = "2";
	Entry = "3";
	Entry = "4";
	Entry = "5";
	Entry = "6";
	Entry = "7";
	Entry = "8";
	Entry = "9";
}
DefineSwitch "列車番号10位"{
GroupCommon = "n05-19列車番号10位";
	Entry = "0";
	Entry = "1";
	Entry = "2";
	Entry = "3";
	Entry = "4";
	Entry = "5";
	Entry = "6";
	Entry = "7";
	Entry = "8";
	Entry = "9";
}
DefineSwitch "列車番号1位"{
GroupCommon = "n05-19列車番号1位";
	Entry = "S";
	Entry = "K";
	Entry = "T";
	Entry = "無表示";
}
DefineSwitch "■車両設定"{
}
DefineSwitch "編成"{
GroupCommon = "n05-19編成";
	Entry = "19";
	Entry = "20";
	Entry = "21";
	Entry = "22";
	Entry = "23";
}
DefineSwitch "号車"{
	Entry = "1号車(西船橋方先頭)";	//( 07-100)
	Entry = "10号車(中野方先頭)";	//( 07-000)
}
DefineSwitch "仕様"{
GroupCommon = "n05-19仕様";
	Entry = "営団";
	Entry = "メトロ1";
	Entry = "メトロ2";
}
DefineSwitch "遮光幕"{
	Entry = "自動";
	Entry = "開";
	Entry = "閉";
}
DefineSwitch "床下汚し"{
GroupCommon = "n05-19床下汚し";
	Entry = "切";
	Entry = "入";
}
DefineSwitch "簡易影"{
	GroupCommon = "n05-19簡易陰";
	Entry = "入";
	Entry = "切";
}

PrimaryAssembly{
	Axle "wheel1"{
		ModelFileName = "../n_TRTA07_y_1/wheel.x";
		CastShadow = no;
		AlphaZeroTest = 0,1;
		Diameter = 0.86;
		Symmetric = 16;
		Coord = (7.95,0.43);
	}
	Axle "wheel2"{
		ModelFileName = "../n_TRTA07_y_1/wheel.x";
		CastShadow = no;
		AlphaZeroTest = 0,1;
		Diameter = 0.86;
		Symmetric = 16;
		Coord = (5.85,0.43);
	}
	Axle "wheel3"{
		ModelFileName = "../n_TRTA07_y_1/wheel.x";
		CastShadow = no;
		AlphaZeroTest = 0,1;
		Diameter = 0.86;
		Symmetric = 16;

		Coord = (-7.95,0.43);
	}
	Axle "wheel4"{
		ModelFileName = "../n_TRTA07_y_1/wheel.x";
		CastShadow = no;
		AlphaZeroTest = 0,1;
		Diameter = 0.86;
		Symmetric = 16;
		Coord = (-5.85,0.43);
	}
	Body "Bogie1"{
		ModelFileName = "../n_TRTA07_y_1/bogie_101.x";
		ApplySwitch "床下汚し"{
			Case 1:
				ShiftTexture = 0, 0.0, 0.5;
				ShiftTexture = 1, 0.0, 0.5;
				ShiftTexture = 2, 0.0, 0.5;
				ShiftTexture = 3, 0.0, 0.5;
		}
		JointZY "wheel1"{
			AttachCoord = (0,0);
			LocalCoord = (1.05,0);
		}
		JointZY "wheel2"{
			AttachCoord = (0,0);
			LocalCoord = (-1.05,0);
		}
	}
	Body "Bogie2"{
		ModelFileName = "../n_TRTA07_y_1/bogie_101.x";
		Turn = yes;
		ApplySwitch "床下汚し"{
			Case 1:
				ShiftTexture = 0, 0.0, 0.5;
				ShiftTexture = 1, 0.0, 0.5;
				ShiftTexture = 2, 0.0, 0.5;
				ShiftTexture = 3, 0.0, 0.5;
		}
		JointZY "wheel3"{
			AttachCoord = (0,0);
			LocalCoord = (1.05,0);
		}
		JointZY "wheel4"{
			AttachCoord = (0,0);
			LocalCoord = (-1.05,0);
		}
	}
	Body "Dummy"{
		ModelFileName = "";
		JointZY "Bogie1"{
			AttachCoord = (0.0, 0.57);
			LocalCoord = (6.9, 1.0);
		}
		JointZY "Bogie2"{
			AttachCoord = (0.0, 0.57);
			LocalCoord = (-6.9, 1.0);
		}
	}
	Object3D "MainBody"{
		ModelFileName = "body_100.x";
		NoShadow = 3,4,5,6,7;
		NoCastShadow = 16,17,56,57,68,69,70,72;
		Transparent = 59,60,61,62,63;
		If ("遮光幕"==0 && !"_FRONT"&&!"_CONNECT1")||"遮光幕"==2{
					ShiftTexture = 59, 0.25, 0.0;
			}
		If "電源"==0{
				ApplySwitch "前照灯"{
					Case 0:
						If !"_FRONT"&&!"_CONNECT1"{
							ChangeTexture = 0, "tex/ライト点.png";
							NoShadow = 0;
							ChangeMaterial{
								MaterialID = 0;
								Emissive = 1.0, 1.0, 1.0;
　　　　　	　　					}
						}
					Case 1:
						ChangeTexture = 0, "tex/ライト点.png";
						NoShadow = 0;
						ChangeMaterial{
							MaterialID = 0;
							Emissive = 1.0, 1.0, 1.0;
　　　　　	　　				}
				}

				ApplySwitch "尾灯"{
					Case 0:
						If "_FRONT"&&!"_CONNECT1"{
							ChangeTexture = 1, "tex/テール点.png";
							NoShadow = 1;
							ChangeMaterial{
								MaterialID = 1;
								Emissive = 1.0, 1.0, 1.0;
　　　　　	　　					}
						}
					Case 1:
						ChangeTexture = 1, "tex/テール点.png";
						NoShadow = 1;
						ChangeMaterial{
							MaterialID = 1;
							Emissive = 1.0, 1.0, 1.0;
　　　　　	　　				}
				}
			If "客室照明"==0{
					ChangeMaterial{
						MaterialID = 22,23,24,25,26,27,28,29,30,31,34,35,36,37,38,39,40,41,42,43,44,47,48,49,50,51,52;
						Emissive = 1.0, 1.0, 1.0;
　　　　　	　　		}
			}
			If "運転室灯"==1 || ("運転室灯"==0 && "_FRONT"){
					ChangeMaterial{
						MaterialID = 32,33,54,55;
						Emissive = 1.0, 1.0, 1.0;
　　　　　	　　		}
			}
								ApplySwitch "行先"{
									Case 1:
									Case 2:
										ShiftTexture = 3, -0.25, 0.0625;
									Case 3:
										ShiftTexture = 3, -0.25, 0.125;
									Case 4:
										ShiftTexture = 3, -0.25, 0.1875;
									Case 5:
										ShiftTexture = 3, -0.25, 0.25;
									Case 6:
										ShiftTexture = 3, -0.25, 0.3125;
									Case 7:
										ShiftTexture = 3, -0.25, 0.375;
									Default:
										ChangeAlpha = 3, 0.0;
								}
								ApplySwitch "行先"{
									Case 1:
										ShiftTexture = 4, 0.1875, 0.0;
									Case 2:
										ShiftTexture = 4, 0.1875, 0.03125;
									Case 3:
										ShiftTexture = 4, 0.1875, 0.0625;
									Case 4:
										ShiftTexture = 4, 0.1875, 0.09375;
									Case 5:
										ShiftTexture = 4, 0.1875, 0.125;
									Case 6:
										ShiftTexture = 4, 0.1875, 0.15625;
									Case 7:
										ShiftTexture = 4, 0.1875, 0.1875;
									Default:
										ChangeAlpha = 4, 0.0;
								}
					ApplySwitch "列車番号100位"{
						Case 0:
							ShiftTexture = 5, 0.03125, 0.0;
						Case 1:
							ShiftTexture = 5, 0.03125, -0.01611328125;
						Case 2:
							ShiftTexture = 5, 0.03125, -0.0322265625;
						Case 3:
							ShiftTexture = 5, 0.03125, -0.0483398438;
						Case 4:
							ShiftTexture = 5, 0.03125, -0.064453125;
						Case 5:
							ShiftTexture = 5, 0.03125, -0.0805664062;
						Case 6:
							ShiftTexture = 5, 0.03125, -0.0966796875;
						Case 7:
							ShiftTexture = 5, 0.03125, -0.112792969;
						Case 8:
							ShiftTexture = 5, 0.03125, -0.12890625;
						Case 9:
							ShiftTexture = 5, 0.03125, -0.145019531;
						Default:
							ChangeAlpha = 5, 0.0;
					}
					ApplySwitch "列車番号10位"{
						Case 0:
							ShiftTexture = 6, 0.03125, 0.01611328125;
						Case 1:
							ShiftTexture = 6, 0.03125, 0.0;
						Case 2:
							ShiftTexture = 6, 0.03125, -0.01611328125;
						Case 3:
							ShiftTexture = 6, 0.03125, -0.0322265625;
						Case 4:
							ShiftTexture = 6, 0.03125, -0.0483398438;
						Case 5:
							ShiftTexture = 6, 0.03125, -0.064453125;
						Case 6:
							ShiftTexture = 6, 0.03125, -0.0805664062;
						Case 7:
							ShiftTexture = 6, 0.03125, -0.0966796875;
						Case 8:
							ShiftTexture = 6, 0.03125, -0.112792969;
						Case 9:
							ShiftTexture = 6, 0.03125, -0.12890625;
						Default:
							ChangeAlpha = 6, 0.0;
					}
					ApplySwitch "列車番号1位"{
						Case 0:
							ShiftTexture = 7, 0.03125, -0.12890625;
						Case 1:
							ShiftTexture = 7, 0.03125, -0.145019531;
						Case 2:
							ShiftTexture = 7, 0.03125, -0.161132812;
						Default:
							ChangeAlpha = 7, 0.0;
						}

		}Else{
			ChangeAlpha = 3, 0.0;
				ChangeAlpha = 4, 0.0;
				ChangeAlpha = 5, 0.0;
				ChangeAlpha = 6, 0.0;
				ChangeAlpha = 7, 0.0;
		}

		ApplySwitch "号車"{
			Case 1:
				If "仕様">0{
					ShiftTexture = 60, -0.3125, 0.0;
				}
				ShiftTexture = 67, 0.125, 0.125;
		}
		ApplySwitch "仕様"{
			Case 0:
				ChangeAlpha = 65, 0.0;
				ChangeAlpha = 66, 0.0;
				NoShadow = 65,66;
			Case 1:
				ChangeAlpha = 64, 0.0;
				ChangeAlpha = 71, 0.0;
				NoShadow = 64,71;
				NoCastShadow = 65;
				ShiftTexture = 63, 0.0, 0.375;
			Case 2:
				ChangeAlpha = 64, 0.0;
				ChangeAlpha = 71, 0.0;
				NoShadow = 64,71;
				NoCastShadow = 65;
				ShiftTexture = 61, 0.0, 0.125;
		}
		ApplySwitch "編成"{
			Case 0:
				ApplySwitch "号車"{
					Case 0:
					Case 1:
						ShiftTexture = 56, 0.5, 0.0;
						ShiftTexture = 57, 0.5, 0.0;
				}
			Case 1:
				ApplySwitch "号車"{
					Case 0:
						ShiftTexture = 56, 0.0, 0.125;
						ShiftTexture = 57, 0.0, 0.125;
					Case 1:
						ShiftTexture = 56, 0.5, 0.125;
						ShiftTexture = 57, 0.5, 0.125;
				}
				ShiftTexture = 46, 0.125, 0.0;
			Case 2:
				ApplySwitch "号車"{
					Case 0:
						ShiftTexture = 56, 0.0, 0.25;
						ShiftTexture = 57, 0.0, 0.25;
					Case 1:
						ShiftTexture = 56, 0.5, 0.25;
						ShiftTexture = 57, 0.5, 0.25;
				}
				ShiftTexture = 46, 0.0, 0.125;
			Case 3:
				ApplySwitch "号車"{
					Case 0:
						ShiftTexture = 56, 0.0, 0.375;
						ShiftTexture = 57, 0.0, 0.375;
					Case 1:
						ShiftTexture = 56, 0.5, 0.375;
						ShiftTexture = 57, 0.5, 0.375;
				}
				ShiftTexture = 46, 0.125, 0.125;
			Case 4:
				ApplySwitch "号車"{
					Case 0:
						ShiftTexture = 56, 0.0, 0.5;
						ShiftTexture = 57, 0.0, 0.5;
					Case 1:
						ShiftTexture = 56, 0.5, 0.5;
						ShiftTexture = 57, 0.5, 0.5;
				}
				ShiftTexture = 46, -0.25, 0.625;
		}
		Joint3D "Dummy"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "SideWindow"{
		ModelFileName = "w.x";
		Transparent = 0;
		If "仕様" >=1 && "号車"==1 {
			ChangeModel = "w1.x", 1.0;
		}
		Joint3D "Dummy"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "yuka"{
		ModelFileName = "";
		ApplySwitch "床下汚し"{
			Case 1:
				ChangeTexture = 0, "tex/床下1.png";
		}
		ApplySwitch "号車"{
			Case 0:ChangeModel = "yuka101.x", 1.0;
			Case 1:ChangeModel = "yuka001.x", 1.0;
		}
		Joint3D "Dummy"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "Doorll"{
		ModelFileName = "Doorl.x";
		Transparent = 5;
		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;
			}
		}
		ApplySwitch "編成"{
			Case 6:
				ShiftTexture = 2, 0.0, 0.125;
			Case 7:
				ShiftTexture = 2, 0.0, 0.0625;
			Default :
				ApplySwitch "仕様"{
					Case 2,3:
						ShiftTexture = 2, 0.0, 0.0625;
				}
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}

	Object3D "Doorlr"{
		ModelFileName = "Doorr.x";
		Transparent = 5;
		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;
			}
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	Object3D "Doorrl"{
		ModelFileName = "Doorr.x";
		Transparent = 5;
		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;
			}
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
			AttachDir = (0.0, 0.0, -1.0);
		}
	}

	Object3D "Doorrr"{
		ModelFileName = "Doorl.x";
		Transparent = 5;
		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;
			}
		}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
			AttachDir = (0.0, 0.0, -1.0);
		}
	}
	Object3D "Doorl"{
		ModelFileName = "../n_TRTA07_y_1/tojime.x";
		StaticRotation{
			RotationAxis = (0.0, 1.0, 0.0);
			RotationAngle = 180;
		}
		If "編成" <=5 && "仕様" ==3{
			ChangeModel = "../n_TRTA07_y_1/tojime1.x", 1.0;
		}
		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 = (1.4, 3.255, 0.0);
		}
	}
	Object3D "Doorr"{
		ModelFileName = "../n_TRTA07_y_1/tojime.x";
		If "編成" <=5 && "仕様" ==3{
			ChangeModel = "../n_TRTA07_y_1/tojime1.x", 1.0;
		}
		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 = (-1.4, 3.255, 0.0);
		}
	}
	Object3D "Shadow"{
		ModelFileName = "../n_TRTA07_y_1/Shadow.x";
		NoCastShadow = 0;
			ApplySwitch "簡易影"{
			Case 1:
			ChangeModel = "", 1.0;
			}
		Joint3D "MainBody"{
			AttachCoord = (0.0, 0.0, 0.0);
		}
	}
	FrontCabin{
		Joint3D "MainBody"{
			AttachCoord = (0.0,0.0,0.0);
		}
	}
}

