Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void RandomizationOptionMenu(){
- int SubscreenShift = -54;
- int XLoc = 16;
- int Indent = 8;
- int ItemState = 3;
- int CharacterState = 0;
- if(GetCharacterFromFilename() != -1)
- CharacterState = 3;
- int CurrentChar = 0;
- int Textshift = 16;
- bool StoryModeSwitch = true;
- int Seed1[] = "Seed:";
- int Dash[] = "-";
- int Seed2[] = "SecondSeed:";
- int StartingItem[] = "Starting Spell:";
- int CharacterSelection[] = "Character Selection";
- int UnmaskCharacter[] = "Unmask";
- int Sound[] = "Sound Wave";
- int Wind[] = "Wind";
- int Magic[] = "Magic Stream";
- int RandItem[] = "Randomize";
- int SeedPick[] = "Pick from Seed";
- int RandPick[] = "Pick Randomly";
- int Choose[] = "Pick manually";
- int Name[] = "Pick from file name";
- int StoryMode[] = "Story Mode:";
- int On[] = "On";
- int Off[] = "Off";
- int Start[] = "Start!";
- int Outfit[] = "Outfit";
- int Normal[] = "Normal";
- int Summer[] = "Beachtime";
- int Snow[] = "Snowsuit";
- int Olsov[] = "Olsov";
- int Gaius[] = "Gaius";
- int Soccer[] = "Soccer Uniform";
- int Blood[] = "Blood";
- bool OutfitOption = false;
- int OutfitState = 0;
- int MaxOutfit = 0;
- int CurrentCharBackup =0;
- int CursorPosition = 0; //0 = seed, 1 = Starting Item, 2 = story mode, 3 = characterselect, 4 = unmask, 5 = outfit, 6 = start
- bool DisableUp = false;
- int StoryModeArray[] = {1,1,1, 1,1,1, 1,1,1, 1,1,1, 0,1,0, 0,0,0, 1,0,1, 0, 1,1,1, 0, 0,0,0,0, 1, 0,1,1,0,0, 0,1,1};
- int CursorOffset = -1;
- int SeedEntryState = 0;
- RAND_FLAGS[RF_SEED_RANDOMIZED] = 1;
- int OldX;
- int OldY;
- int APromptXOffset = -16;
- int APromptYOffset = -4;
- while(true){
- if(CurrentChar != 0){
- DrawCharacterInfo(CurrentChar); //The bio and stuff off to the right
- }
- else{
- Tango_ClearSlot(0);
- Tango_ClearSlot(1);
- Tango_ClearSlot(2);
- }
- Screen->DrawString(2, XLoc, 0 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x0A, -1, TF_NORMAL, Seed1, OP_OPAQUE);
- Screen->DrawInteger(2, XLoc + Indent, 10 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, -1, -1, RAND_FLAGS[RF_SEED1], 0, OP_OPAQUE);
- Screen->DrawString(2, XLoc+Indent+16, 10 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Dash, OP_OPAQUE);
- Screen->DrawInteger(2, XLoc + Indent + 24, 10 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, -1, -1, RAND_FLAGS[RF_SEED2], 0, OP_OPAQUE);
- // Screen->DrawString(2, XLoc, 30 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x0A, -1, TF_NORMAL, Seed2, OP_OPAQUE);
- // Screen->DrawInteger(2, XLoc + Indent, 40 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, -1, -1, RAND_FLAGS[RF_SEED1], 0, OP_OPAQUE);
- Screen->DrawString(2, XLoc, 30 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x0A, -1, TF_NORMAL, StartingItem, OP_OPAQUE);
- if(ItemState == 0)
- Screen->DrawString(2, XLoc + Indent, 40 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Sound, OP_OPAQUE);
- else if(ItemState == 1)
- Screen->DrawString(2, XLoc + Indent, 40 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Wind, OP_OPAQUE);
- else if(ItemState == 2)
- Screen->DrawString(2, XLoc + Indent, 40 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Magic, OP_OPAQUE);
- else if(ItemState == 3)
- Screen->DrawString(2, XLoc + Indent, 40 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, RandItem, OP_OPAQUE);
- Screen->DrawString(2, XLoc, 60 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x0A, -1, TF_NORMAL, StoryMode, OP_OPAQUE);
- if(StoryModeSwitch == true)
- Screen->DrawString(2, XLoc + Indent, 70 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, On, OP_OPAQUE);
- else
- Screen->DrawString(2, XLoc + Indent, 70 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Off, OP_OPAQUE);
- Screen->DrawString(2, XLoc, 90 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x0A, -1, TF_NORMAL, CharacterSelection, OP_OPAQUE);
- if(CharacterState == 0)
- Screen->DrawString(2, XLoc + Indent, 100 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, SeedPick, OP_OPAQUE);
- else if(CharacterState == 1)
- Screen->DrawString(2, XLoc + Indent, 100 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, RandPick, OP_OPAQUE);
- else if(CharacterState == 2)
- Screen->DrawString(2, XLoc + Indent, 100 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Choose, OP_OPAQUE);
- else if(CharacterState == 3)
- Screen->DrawString(2, XLoc + Indent, 100 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Name, OP_OPAQUE);
- Screen->DrawTile(2, XLoc + Indent, 110 + SubscreenShift + Textshift, 8697, 2, 2, 7, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE);
- if(CurrentChar == 0)
- Screen->DrawTile(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 5, 10360, 1, 1, 11, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE);
- else if(OutfitState == 0){
- if(CurrentChar == 14) //Exception for Sasic
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4107, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- else
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, Characters[CurrentChar], 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- Screen->DrawString(2, XLoc + Indent, 140 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, UnmaskCharacter, OP_OPAQUE);
- if(OutfitOption){
- Screen->DrawString(2, XLoc, 150 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x0A, -1, TF_NORMAL, Outfit, OP_OPAQUE);
- Screen->DrawString(2, XLoc+18, 186 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x88, -1, TF_NORMAL, Start, OP_OPAQUE);
- }
- else
- Screen->DrawString(2, XLoc+18, 166 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x88, -1, TF_NORMAL, Start, OP_OPAQUE);
- if(Link->PressUp && !DisableUp){
- Game->PlaySound(5);
- if(CursorPosition == 0)
- CursorPosition = 6;
- else if(CursorPosition == 6 && !OutfitOption)
- CursorPosition = 4;
- else
- CursorPosition--;
- }
- if(Link->PressDown && !DisableUp){
- Game->PlaySound(5);
- if(CursorPosition == 6)
- CursorPosition = 0;
- else if(CursorPosition == 4 && !OutfitOption)
- CursorPosition = 6;
- else
- CursorPosition++;
- }
- if(CursorPosition == 0){ //Seed
- //Put stuff for changing seed here
- if(!DisableUp)
- Screen->FastCombo(4, XLoc + APromptXOffset, 10 + SubscreenShift + Textshift + CursorOffset + APromptYOffset, 4021, 7, OP_OPAQUE);
- else{
- if(SeedEntryState == 1){
- Screen->DrawTile(3, XLoc, 10 + SubscreenShift + Textshift + CursorOffset, 1536, 1, 1, 4, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE); //Cursor
- if(Link->PressUp){
- RAND_FLAGS[RF_SEED1]++;
- }
- if(Link->PressDown){
- RAND_FLAGS[RF_SEED1]--;
- }
- if(Link->PressLeft)
- RAND_FLAGS[RF_SEED1]-=10;
- if(Link->PressRight)
- RAND_FLAGS[RF_SEED1]+=10;
- if(RAND_FLAGS[RF_SEED1]>255)
- RAND_FLAGS[RF_SEED1]=0;
- if(RAND_FLAGS[RF_SEED1]<0)
- RAND_FLAGS[RF_SEED1]=255;
- if(Link->PressA){
- Game->PlaySound(5);
- SeedEntryState = 2;
- Screen->D[2] = 1;
- }
- }
- if(SeedEntryState == 2 && Screen->D[2] == 0){
- Screen->DrawTile(3, XLoc + 24, 10 + SubscreenShift + Textshift + CursorOffset, 1536, 1, 1, 4, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE); //Cursor
- if(Link->PressUp){
- RAND_FLAGS[RF_SEED2]++;
- }
- if(Link->PressDown){
- RAND_FLAGS[RF_SEED2]--;
- }
- if(Link->PressLeft)
- RAND_FLAGS[RF_SEED2]-=10;
- if(Link->PressRight)
- RAND_FLAGS[RF_SEED2]+=10;
- if(RAND_FLAGS[RF_SEED2]>255)
- RAND_FLAGS[RF_SEED2]=0;
- if(RAND_FLAGS[RF_SEED2]<0)
- RAND_FLAGS[RF_SEED2]=255;
- if(Link->PressA){
- Game->PlaySound(5);
- Screen->D[2] = 1;
- if(NewRandomizationCore() == 1){
- Screen->Message(2188);
- Waitframe();
- SeedEntryState = 0;
- RAND_FLAGS[RF_SEED1] = OldX;
- RAND_FLAGS[RF_SEED2] = OldY;
- DisableUp = false;
- }
- else{
- SeedEntryState = 0;
- DisableUp = false;
- OldX = RAND_FLAGS[RF_SEED1];
- OldY = RAND_FLAGS[RF_SEED2];
- }
- }
- }
- }
- if(SeedEntryState == 0){
- Screen->DrawTile(3, XLoc, 10 + SubscreenShift + Textshift + CursorOffset, 1536, 1, 1, 4, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE); //Cursor
- }
- if(Link->PressA && Screen->D[2] == 0){
- Game->PlaySound(5);
- DisableUp = true;
- SeedEntryState = 1;
- CurrentChar = 0; //Hide the character
- Screen->D[1] = 0; //Reset the choice
- OldX = RAND_FLAGS[RF_SEED1];
- OldY = RAND_FLAGS[RF_SEED2];
- for(int i = 0; i<SizeOfArray(ItemRandomizationArray); i++){
- ItemRandomizationArray[i] = 0;
- }
- for(int i = 0; i<SizeOfArray(ItemArray); i++){
- ItemArray[i] = 0;
- }
- }
- }
- if(CursorPosition == 1){ //Starting Item
- Screen->DrawTile(3, XLoc, 40 + SubscreenShift + Textshift + CursorOffset, 1536, 1, 1, 4, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE); //Cursor
- if(Link->PressLeft){
- Game->PlaySound(5);
- if(ItemState == 0)
- ItemState = 3;
- else
- ItemState--;
- }
- if(Link->PressRight){
- Game->PlaySound(5);
- if(ItemState == 3)
- ItemState = 0;
- else
- ItemState++;
- }
- }
- if(CursorPosition == 2){ //StoryMode
- Screen->DrawTile(3, XLoc, 70 + SubscreenShift + Textshift + CursorOffset, 1536, 1, 1, 4, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE); //Cursor
- if(Link->PressLeft || Link->PressRight){
- Game->PlaySound(5);
- if(StoryModeSwitch == false){
- StoryModeSwitch = true;
- if(CurrentChar >0){
- if(StoryModeArray[CurrentChar-1] == 0){ //We just turned story mode on and this character lacks a story mode
- CurrentChar = 0; //Hide the character
- Screen->D[1] = 0; //Reset the choice
- }
- }
- }
- else
- StoryModeSwitch = false;
- }
- }
- if(CursorPosition == 3){ //Character
- Screen->DrawTile(3, XLoc, 100 + SubscreenShift + Textshift + CursorOffset, 1536, 1, 1, 4, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE); //Cursor
- if(Link->PressLeft){
- CurrentChar = 0; //Hide the character
- OutfitState = 0;
- OutfitOption = false;
- RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER_STORY_BACKUP] = 0;
- RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER] = 0;
- Screen->D[1] = 0;
- Game->PlaySound(5);
- if(CharacterState == 0)
- CharacterState = 3;
- else
- CharacterState--;
- }
- if(Link->PressRight){
- CurrentChar = 0; //Hide the character
- OutfitState = 0;
- OutfitOption = false;
- RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER_STORY_BACKUP] = 0;
- RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER] = 0;
- Screen->D[1] = 0;
- Game->PlaySound(5);
- if(CharacterState == 3)
- CharacterState = 0;
- else
- CharacterState++;
- }
- if(CharacterState == 2){ //Choose
- if(CurrentChar == 0)
- DisableUp = true;
- else
- DisableUp = false;
- Screen->FastCombo(4, XLoc + APromptXOffset, 100 + SubscreenShift + Textshift + CursorOffset + APromptYOffset, 4021, 7, OP_OPAQUE);
- if(Link->PressA){
- Game->PlaySound(67);
- CurrentCharBackup = CurrentChar;
- //CurrentChar = CharacterSelect();
- Screen->D[0] = 1;
- Waitframe();
- RunFFCScript(264,0);
- }
- }
- else
- DisableUp = false;
- }
- if(CursorPosition == 4){ //Unmask
- Screen->DrawTile(3, XLoc, 140 + SubscreenShift + Textshift + CursorOffset, 1536, 1, 1, 4, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE); //Cursor
- Screen->FastCombo(4, XLoc + APromptXOffset, 140 + SubscreenShift + Textshift + CursorOffset + APromptYOffset, 4021, 7, OP_OPAQUE);
- if(Link->PressA && CharacterState != 2){
- Game->PlaySound(67);
- if(CharacterState == 0){ //Pick from seed
- if(StoryModeSwitch == true)
- CurrentChar = RAND_FLAGS[RF_CHARACTER_STORY_BACKUP];
- else
- CurrentChar = RAND_FLAGS[RF_CHARACTER];
- }
- else if(CharacterState == 1){ //Pick randomly
- int CharacterSelected;
- if(StoryModeSwitch == true){
- do{
- RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER_STORY_BACKUP] = srand(1,39);
- CharacterSelected = RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER_STORY_BACKUP];
- }
- while(StoryModeArray[CharacterSelected-1] == 0);
- CurrentChar = RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER_STORY_BACKUP];
- }
- else{
- do{
- RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER] = srand(1,39);
- CharacterSelected = RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER];
- }
- while(CharacterSelected == 22 || CharacterSelected == 16 || CharacterSelected == 17 || CharacterSelected == 18); //No selecting a Reikon character randomly
- CurrentChar = RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER];
- }
- }
- else if(CharacterState == 3){ //Pick from file name
- CurrentChar = GetCharacterFromFilename();
- if(CurrentChar == 0)
- Game->PlaySound(6);
- }
- }
- }
- if(CursorPosition == 5){ //Outfit
- Screen->DrawTile(3, XLoc, 160 + SubscreenShift + Textshift + CursorOffset, 1536, 1, 1, 4, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE); //Cursor
- if(Link->PressRight){
- Game->PlaySound(5);
- if(OutfitState == MaxOutfit)
- OutfitState = 0;
- else
- OutfitState++;
- }
- if(Link->PressLeft){
- Game->PlaySound(5);
- if(OutfitState == 0)
- OutfitState = MaxOutfit;
- else
- OutfitState--;
- }
- }
- if(CursorPosition == 6){ //Start
- if(!OutfitOption)
- Screen->DrawTile(3, XLoc-Indent+18, 166 + SubscreenShift + Textshift + CursorOffset, 1536, 1, 1, 4, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE); //Cursor
- else
- Screen->DrawTile(3, XLoc-Indent+18, 186 + SubscreenShift + Textshift + CursorOffset, 1536, 1, 1, 4, -1, -1, 0, 0, 0, 0, true, OP_OPAQUE); //Cursor
- if(Link->PressA || Link->PressStart){
- //Pick starting items.
- if(ItemState == 0)
- RAND_FLAGS[RF_STARTING_ITEM] = 1; //Start with sound
- else if(ItemState == 1)
- RAND_FLAGS[RF_STARTING_ITEM] = 0; //Start with wind
- else if(ItemState == 2)
- RAND_FLAGS[RF_STARTING_ITEM] = 2; //Start with magic stream
- if(ItemState == 3)
- RAND_FLAGS[RF_STARTING_ITEM] = srand(0,2); //Wind vs Sound vs Magic Steam, randomized regardless of pick to ensure next srand call works. 0 is wind start, 1 is sound start, 2 is magic steam start.
- else
- int dummy = srand(0,2); //Calling this here just to make sure the srands are consistent.
- RAND_FLAGS[RF_STARTING_ITEM_RANDOMIZED] = 0; //This is just set this way to make sure my older system always spawns RF_STARTING_ITEM.
- //Pick Story Mode.
- if(StoryModeSwitch == true)
- RAND_FLAGS[RF_STORY_MODE_ON] = 1;
- else
- RAND_FLAGS[RF_STORY_MODE_ON] = 0;
- //Pick Character.
- if(CurrentChar == 0){ //Character has not been unmasked yet
- if(CharacterState == 0){ //Pick from seed
- if(StoryModeSwitch == true)
- CurrentChar = RAND_FLAGS[RF_CHARACTER_STORY_BACKUP];
- else
- CurrentChar = RAND_FLAGS[RF_CHARACTER];
- }
- else if(CharacterState == 1){ //Pick Randomly
- int CharacterSelected;
- if(StoryModeSwitch == true){
- do{
- RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER_STORY_BACKUP] = srand(1,39);
- CharacterSelected = RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER_STORY_BACKUP];
- }
- while(StoryModeArray[CharacterSelected-1] == 0);
- CurrentChar = RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER_STORY_BACKUP];
- }
- else{
- do{
- RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER] = srand(1,39);
- CharacterSelected = RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER];
- }
- while(CharacterSelected == 22 || CharacterSelected == 16 || CharacterSelected == 17 || CharacterSelected == 18); //No selecting a Reikon character randomly
- CurrentChar = RAND_FLAGS[RF_TRUE_RANDOMIZED_CHARACTER];
- }
- }
- else if(CharacterState == 3){ //Pick from file name
- CurrentChar = GetCharacterFromFilename();
- if(CurrentChar == 0){ //Filename is not valid, so time to pick from the seed instead
- if(StoryModeSwitch == true)
- CurrentChar = RAND_FLAGS[RF_CHARACTER_STORY_BACKUP];
- else
- CurrentChar = RAND_FLAGS[RF_CHARACTER];
- }
- if(CurrentChar >0){
- if(StoryModeArray[CurrentChar-1] == 0){ //That character doesn't have a story mode
- RAND_FLAGS[RF_STORY_MODE_ON] = 0;
- }
- }
- }
- }
- if(CurrentChar > 0){ //Character has now been unmasked
- int ring;
- if(CurrentChar == 1)
- ring = RHONE_RING;
- if(CurrentChar == 2)
- ring = SEINE_RING;
- if(CurrentChar == 3)
- ring = LOIRE_RING;
- if(CurrentChar == 4)
- ring = HITO_RING;
- if(CurrentChar == 5)
- ring = JACK_RING;
- if(CurrentChar == 6)
- ring = WILL_RING;
- if(CurrentChar == 7)
- ring = NAIYA_RING;
- if(CurrentChar == 8)
- ring = JANDRA_RING;
- if(CurrentChar == 9)
- ring = TYRE_RING;
- if(CurrentChar == 10)
- ring = EMILY_RING;
- if(CurrentChar == 11)
- ring = LUCAS_RING;
- if(CurrentChar == 12)
- ring = CAELAN_RING;
- if(CurrentChar == 13)
- ring = FLECT_RING;
- if(CurrentChar == 14){
- if(OutfitState == 0)
- ring = SASIC_RING;
- if(OutfitState == 1)
- ring = SASIC_RING_2;
- if(OutfitState == 2)
- ring = SASIC_RING_3;
- }
- if(CurrentChar == 15)
- ring = ZELDA_RING;
- if(CurrentChar == 16)
- ring = HOLM_RING;
- if(CurrentChar == 17)
- ring = MIRR_RING;
- if(CurrentChar == 18)
- ring = HART_RING;
- if(CurrentChar == 19)
- ring = BASTILLE_RING;
- if(CurrentChar == 20)
- ring = CHAINED_RING;
- if(CurrentChar == 21)
- ring = HORIZON_RING;
- if(CurrentChar == 22)
- ring = VANICE_RING;
- if(CurrentChar == 23)
- ring = VEN_RING;
- if(CurrentChar == 24)
- ring = WAN_RING;
- if(CurrentChar == 25)
- ring = SUE_RING;
- if(CurrentChar == 26)
- ring = GALE_RING;
- if(CurrentChar == 27)
- ring = CALAIS_RING;
- if(CurrentChar == 28)
- ring = ZEPHYR_RING;
- if(CurrentChar == 29)
- ring = NOTOS_RING;
- if(CurrentChar == 30)
- ring = BOREAS_RING;
- if(CurrentChar == 31)
- ring = AUTIMECIA_RING;
- if(CurrentChar == 32)
- ring = QUINN_RING;
- if(CurrentChar == 33)
- ring = MATO_RING;
- if(CurrentChar == 34){
- if(OutfitState == 1)
- ring = MILES_RING_2;
- else
- ring = MILES_RING;
- }
- if(CurrentChar == 35)
- ring = KAVERI_RING;
- if(CurrentChar == 36)
- ring = AVA_RING;
- if(CurrentChar == 37)
- ring = XAYA_RING;
- if(CurrentChar == 38)
- ring = DRACUS_RING;
- if(CurrentChar == 39)
- ring = LUMEN_RING;
- Link->Item[ring] = true;
- }
- //Outfit
- G[G_OUTFIT] = OutfitState;
- OutfitCopyTile();
- //Autimecia Items
- if(Rand(1,28) <=4)
- RAND_FLAGS[6] = Choose(72,10,119,70);
- else
- RAND_FLAGS[6] = Rand(204,227);
- do{
- if(Rand(1,28) <=4)
- RAND_FLAGS[7] = Choose(72,10,119,70);
- else
- RAND_FLAGS[7] = Rand(204,227);
- }
- while(RAND_FLAGS[7] == RAND_FLAGS[6]);
- do{
- if(Rand(1,28) <=4)
- RAND_FLAGS[8] = Choose(72,10,119,70);
- else
- RAND_FLAGS[8] = Rand(204,227);
- }
- while(RAND_FLAGS[8] == RAND_FLAGS[6] && RAND_FLAGS[8] == RAND_FLAGS[7]);
- do{
- RAND_FLAGS[RF_AUTIMECIA_SIGNATURE] = Rand(1,39);
- }
- while(RAND_FLAGS[RF_AUTIMECIA_SIGNATURE] == 31 || RAND_FLAGS[RF_AUTIMECIA_SIGNATURE] == 30 || RAND_FLAGS[RF_AUTIMECIA_SIGNATURE] == 24 || RAND_FLAGS[RF_AUTIMECIA_SIGNATURE] == 25 || RAND_FLAGS[RF_AUTIMECIA_SIGNATURE] == 5 || RAND_FLAGS[RF_AUTIMECIA_SIGNATURE] == 6); //No rolling her own item or duplicate items
- //Signature Stuff
- SetSpecialAttackMPAtGameInit(); //Now that we've got the character, set up MP costs for their special ability
- G[G_SUBPOSITION] = 27; //And set the subscreen selector position.
- G[G_LINK_EQUIPB] = 228; //And set the item to B.
- //Guaranteed boss fights
- if(RAND_FLAGS[RF_STORY_MODE_ON] == 1 && (Link->Item[EMILY_RING] || Link->Item[LUCAS_RING] || Link->Item[CAELAN_RING]))
- BossArray[3] = 3;
- //Moving the roaming boss for Rivieres
- if((Link->Item[RHONE_RING] || Link->Item[SEINE_RING] || Link->Item[LOIRE_RING]) && StoryModeSwitch == true && RAND_FLAGS[RF_ROAMING_BOSS_ONE] == 15){ //No roaming boss in caverns please
- RAND_FLAGS[RF_ROAMING_BOSS_ONE] = srand(1,14);
- }
- int strcmap[] = "Your Seed Is: %i (%i)\n";
- printf(strcmap, RAND_FLAGS[RF_SEED1], RAND_FLAGS[RF_SEED2]);
- GreatScreenCopyAdventure(); //Now much greater by virtue of being a separate function. Yay, organization!
- __Tango_SlotDefs[17] = 0;
- SetSignatureString();
- Tango_ClearSlot(0);
- Tango_ClearSlot(1);
- Tango_ClearSlot(2);
- return;
- }
- }
- while(Screen->D[0] == 1){
- Waitframe();
- }
- if(Screen->D[0] > 1){
- Tango_ClearSlot(0);
- Tango_ClearSlot(1);
- Tango_ClearSlot(2);
- if(Screen->D[1] != 0)
- CurrentChar = Screen->D[1];
- for(int i = Screen->D[0]; i >0; i--){
- BlackScreen();
- NoInputWaitframes(1);
- }
- Screen->D[0] = 0;
- }
- Screen->D[2] = 0;
- if(CurrentChar >0){
- if(StoryModeArray[CurrentChar-1] == 0 && StoryModeSwitch == true){
- StoryModeSwitch = false;
- }
- }
- if(CurrentChar == 0){ //No character selected
- MaxOutfit = 0;
- OutfitState = 0;
- OutfitOption = false;
- }
- else if(CurrentChar == 10){ //Emily
- OutfitOption = true;
- MaxOutfit = 2;
- if(OutfitState == 0)
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Normal, OP_OPAQUE);
- else if(OutfitState == 1){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Summer, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4362, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- else if(OutfitState == 2){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Snow, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4363, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- }
- else if(CurrentChar == 11){ //Lucas
- OutfitOption = true;
- MaxOutfit = 2;
- if(OutfitState == 0)
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Normal, OP_OPAQUE);
- else if(OutfitState == 1){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Summer, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4364, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- else if(OutfitState == 2){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Snow, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4365, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- }
- else if(CurrentChar == 12){ //Caelan
- OutfitOption = true;
- MaxOutfit = 2;
- if(OutfitState == 0)
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Normal, OP_OPAQUE);
- else if(OutfitState == 1){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Summer, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4366, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- else if(OutfitState == 2){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Snow, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4367, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- }
- else if(CurrentChar == 14){ //Sasic
- OutfitOption = true;
- MaxOutfit = 2;
- if(OutfitState == 0)
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Normal, OP_OPAQUE);
- else if(OutfitState == 1){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Olsov, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4384, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- else if(OutfitState == 2){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Gaius, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4385, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- }
- else if(CurrentChar == 33){ //Mato
- OutfitOption = true;
- MaxOutfit = 2;
- if(OutfitState == 0)
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Normal, OP_OPAQUE);
- else if(OutfitState == 1){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Soccer, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4386, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- else if(OutfitState == 2){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Summer, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4387, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- }
- else if(CurrentChar == 34){ //Miles
- OutfitOption = true;
- MaxOutfit = 2;
- if(OutfitState == 0)
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Normal, OP_OPAQUE);
- else if(OutfitState == 1){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Blood, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4388, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- else if(OutfitState == 2){
- Screen->DrawString(2, XLoc + Indent, 160 + SubscreenShift + Textshift, FONT_Z3SMALL, 0x4A, -1, TF_NORMAL, Summer, OP_OPAQUE);
- Screen->DrawCombo(2, XLoc + Indent + 5, 110 + SubscreenShift + Textshift + 4, 4389, 1, 1, CharactersCSets[CurrentChar], -1, -1, 0, 0, 0, 0, 0, true, OP_OPAQUE);
- }
- }
- else{
- MaxOutfit = 0;
- OutfitState = 0;
- OutfitOption = false;
- }
- if(Link->PressStart && !DisableUp)
- CursorPosition = 6;
- Waitframe();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement