Downloads containing CharactersMinAnim.asc

Downloads
Name Author Game Mode Rating
TSF with JJ2+ Only: Characters Cranky Mutator N/A Download file

File preview

// Generated from charactersMin.j2a animation-index data.
// Each entry maps (source set, original animation, frame) to the
// merged animation ID and relative frame offset after jjANIMSET::load().
namespace CharactersMinAnim {
	const int SET_DEATH = 0;
	const int SET_LORI = 1;
	const int SET_LORIGREEN = 2;
	const int SET_MARIO = 3;
	const int SET_SONIC = 4;
	const int SET_TAILS = 5;
	const int SET_JJ1 = 6;
	const int SET_DEVAN = 7;
	const int SET_YOSHI = 8;
	const int SET_BLUEYOSHI = 9;

	array<int> SetOffsets = {
		0, 2, 86, 167, 250, 337, 374, 392,
		394, 477
	};

	array<int> AnimCounts = {
		2, 84, 81, 83, 87, 37, 18, 2,
		83, 83
	};

	array<string> SetNames = {
		"Death", "Lori", "LoriGreen", "Mario",
		"Sonic", "Tails", "JJ1", "Devan",
		"Yoshi", "BlueYoshi"
	};

	array<int> MergedAnims = {
		0, 1, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 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 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0,
		0, 0, 0, 0, 0, 0, 0, 0
	};

	array<int> StartFrames = {
		0, 0, 0, 11, 18, 25, 26, 50,
		55, 56, 58, 60, 68, 90, 93, 101,
		108, 110, 112, 116, 139, 143, 144, 146,
		147, 175, 178, 180, 208, 211, 213, 221,
		232, 240, 284, 300, 323, 346, 348, 350,
		353, 356, 359, 371, 372, 383, 387, 389,
		401, 409, 413, 420, 424, 426, 430, 439,
		447, 455, 463, 471, 473, 477, 485, 493,
		501, 504, 506, 516, 528, 542, 556, 557,
		558, 572, 588, 596, 603, 609, 617, 624,
		632, 636, 641, 678, 688, 700, 0, 11,
		18, 25, 26, 50, 55, 56, 58, 60,
		68, 90, 93, 101, 108, 110, 112, 116,
		139, 143, 144, 146, 147, 175, 178, 180,
		208, 211, 213, 221, 232, 240, 284, 300,
		323, 346, 348, 350, 353, 356, 359, 371,
		372, 383, 387, 389, 401, 409, 413, 420,
		424, 426, 430, 439, 447, 455, 463, 471,
		473, 477, 485, 493, 501, 504, 506, 516,
		528, 542, 556, 557, 558, 572, 588, 596,
		603, 609, 617, 624, 632, 636, 641, 0,
		11, 18, 25, 30, 50, 52, 54, 56,
		59, 67, 89, 92, 100, 105, 107, 109,
		113, 132, 137, 138, 140, 141, 148, 151,
		153, 161, 163, 165, 171, 182, 187, 207,
		208, 221, 243, 245, 247, 250, 253, 256,
		278, 281, 292, 295, 297, 309, 318, 322,
		329, 333, 335, 338, 347, 355, 363, 371,
		375, 378, 381, 389, 397, 402, 405, 407,
		414, 422, 430, 438, 439, 440, 448, 459,
		466, 474, 479, 486, 494, 500, 504, 539,
		547, 550, 0, 11, 18, 25, 30, 50,
		52, 54, 56, 59, 67, 89, 92, 100,
		105, 107, 109, 113, 132, 137, 138, 140,
		141, 148, 151, 153, 161, 163, 165, 171,
		182, 187, 207, 208, 221, 243, 245, 247,
		250, 253, 256, 278, 281, 292, 295, 297,
		309, 318, 322, 329, 333, 335, 338, 347,
		355, 363, 371, 375, 378, 381, 389, 397,
		402, 405, 407, 414, 422, 430, 438, 439,
		440, 448, 459, 466, 474, 479, 486, 494,
		500, 504, 539, 547, 550, 587, 593, 599,
		608, 0, 8, 12, 13, 15, 20, 25,
		37, 39, 45, 55, 61, 75, 77, 83,
		84, 95, 100, 133, 171, 173, 175, 177,
		182, 190, 195, 201, 203, 206, 219, 221,
		226, 231, 238, 246, 257, 269, 0, 6,
		12, 16, 17, 21, 23, 24, 29, 37,
		38, 41, 43, 47, 49, 51, 53, 55,
		0, 0, 0, 6, 11, 16, 17, 22,
		24, 26, 28, 30, 35, 44, 45, 46,
		52, 54, 57, 62, 81, 84, 85, 86,
		87, 88, 91, 92, 100, 102, 110, 114,
		121, 125, 142, 143, 153, 159, 162, 164,
		168, 171, 174, 180, 184, 192, 195, 197,
		202, 204, 209, 213, 217, 219, 223, 227,
		231, 239, 247, 255, 263, 267, 270, 276,
		280, 281, 283, 291, 297, 303, 309, 310,
		311, 317, 323, 331, 339, 343, 351, 359,
		363, 366, 369, 377, 385, 0, 6, 11,
		16, 17, 22, 24, 26, 28, 30, 35,
		44, 45, 46, 52, 54, 57, 62, 81,
		84, 85, 86, 87, 88, 91, 92, 100,
		102, 110, 114, 121, 125, 142, 143, 153,
		159, 162, 164, 168, 171, 174, 180, 184,
		192, 195, 197, 202, 204, 209, 213, 217,
		219, 223, 227, 231, 239, 247, 255, 263,
		267, 270, 276, 280, 281, 283, 291, 297,
		303, 309, 310, 311, 317, 323, 331, 339,
		343, 351, 359, 363, 366, 369, 377, 385
	};

	array<int> FrameCounts = {
		20, 20, 11, 7, 7, 1, 24, 5,
		1, 2, 2, 8, 22, 3, 8, 7,
		2, 2, 4, 23, 4, 1, 2, 1,
		28, 3, 2, 28, 3, 2, 8, 11,
		8, 44, 16, 23, 23, 2, 2, 3,
		3, 3, 12, 1, 11, 4, 2, 12,
		8, 4, 7, 4, 2, 4, 9, 8,
		8, 8, 8, 2, 4, 8, 8, 8,
		3, 2, 10, 12, 14, 14, 1, 1,
		14, 16, 8, 7, 6, 8, 7, 8,
		4, 5, 37, 10, 12, 10, 11, 7,
		7, 1, 24, 5, 1, 2, 2, 8,
		22, 3, 8, 7, 2, 2, 4, 23,
		4, 1, 2, 1, 28, 3, 2, 28,
		3, 2, 8, 11, 8, 44, 16, 23,
		23, 2, 2, 3, 3, 3, 12, 1,
		11, 4, 2, 12, 8, 4, 7, 4,
		2, 4, 9, 8, 8, 8, 8, 2,
		4, 8, 8, 8, 3, 2, 10, 12,
		14, 14, 1, 1, 14, 16, 8, 7,
		6, 8, 7, 8, 4, 5, 37, 11,
		7, 7, 5, 20, 2, 2, 2, 3,
		8, 22, 3, 8, 5, 2, 2, 4,
		19, 5, 1, 2, 1, 7, 3, 2,
		8, 2, 2, 6, 11, 5, 20, 1,
		13, 22, 2, 2, 3, 3, 3, 22,
		3, 11, 3, 2, 12, 9, 4, 7,
		4, 2, 3, 9, 8, 8, 8, 4,
		3, 3, 8, 8, 5, 3, 2, 7,
		8, 8, 8, 1, 1, 8, 11, 7,
		8, 5, 7, 8, 6, 4, 35, 8,
		3, 37, 11, 7, 7, 5, 20, 2,
		2, 2, 3, 8, 22, 3, 8, 5,
		2, 2, 4, 19, 5, 1, 2, 1,
		7, 3, 2, 8, 2, 2, 6, 11,
		5, 20, 1, 13, 22, 2, 2, 3,
		3, 3, 22, 3, 11, 3, 2, 12,
		9, 4, 7, 4, 2, 3, 9, 8,
		8, 8, 4, 3, 3, 8, 8, 5,
		3, 2, 7, 8, 8, 8, 1, 1,
		8, 11, 7, 8, 5, 7, 8, 6,
		4, 35, 8, 3, 37, 6, 6, 9,
		6, 8, 4, 1, 2, 5, 5, 12,
		2, 6, 10, 6, 14, 2, 6, 1,
		11, 5, 33, 38, 2, 2, 2, 5,
		8, 5, 6, 2, 3, 13, 2, 5,
		5, 7, 8, 11, 12, 11, 6, 6,
		4, 1, 4, 2, 1, 5, 8, 1,
		3, 2, 4, 2, 2, 2, 2, 1,
		10, 37, 6, 5, 5, 1, 5, 2,
		2, 2, 2, 5, 9, 1, 1, 6,
		2, 3, 5, 19, 3, 1, 1, 1,
		1, 3, 1, 8, 2, 8, 4, 7,
		4, 17, 1, 10, 6, 3, 2, 4,
		3, 3, 6, 4, 8, 3, 2, 5,
		2, 5, 4, 4, 2, 4, 4, 4,
		8, 8, 8, 8, 4, 3, 6, 4,
		1, 2, 8, 6, 6, 6, 1, 1,
		6, 6, 8, 8, 4, 8, 8, 4,
		3, 3, 8, 8, 1, 6, 5, 5,
		1, 5, 2, 2, 2, 2, 5, 9,
		1, 1, 6, 2, 3, 5, 19, 3,
		1, 1, 1, 1, 3, 1, 8, 2,
		8, 4, 7, 4, 17, 1, 10, 6,
		3, 2, 4, 3, 3, 6, 4, 8,
		3, 2, 5, 2, 5, 4, 4, 2,
		4, 4, 4, 8, 8, 8, 8, 4,
		3, 6, 4, 1, 2, 8, 6, 6,
		6, 1, 1, 6, 6, 8, 8, 4,
		8, 8, 4, 3, 3, 8, 8, 1
	};

	int Index(int sourceSet, int originalAnim) {
		if(sourceSet < 0 || sourceSet >= int(SetOffsets.length))
			return -1;
		if(originalAnim < 0 || originalAnim >= AnimCounts[sourceSet])
			return -1;
		return SetOffsets[sourceSet] + originalAnim;
	}

	int AnimCount(int sourceSet) {
		if(sourceSet < 0 || sourceSet >= int(AnimCounts.length))
			return 0;
		return AnimCounts[sourceSet];
	}

	string SetName(int sourceSet) {
		if(sourceSet < 0 || sourceSet >= int(SetNames.length))
			return "";
		return SetNames[sourceSet];
	}

	int MergedAnim(int sourceSet, int originalAnim) {
		int index = Index(sourceSet, originalAnim);
		return index < 0 ? 0 : MergedAnims[index];
	}

	int StartFrame(int sourceSet, int originalAnim) {
		int index = Index(sourceSet, originalAnim);
		return index < 0 ? 0 : StartFrames[index];
	}

	int FrameCount(int sourceSet, int originalAnim) {
		int index = Index(sourceSet, originalAnim);
		return index < 0 ? 1 : FrameCounts[index];
	}

	int Frame(int sourceSet, int originalAnim, int frameID) {
		int index = Index(sourceSet, originalAnim);
		if(index < 0)
			return frameID;
		int frameCount = FrameCounts[index];
		if(frameCount <= 0)
			return StartFrames[index];
		return StartFrames[index] + frameID % frameCount;
	}
}