Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Information about object: BattleDummy
- Sprite:
- Solid: false
- Visible: true
- Depth: 0
- Persistent: false
- Parent:
- Children:
- Mask:
- No Physics Object
- Create Event:
- execute code:
- /// FETCH VALUES FOR POKEMON ON THE FIELD
- // Var object holds all the constants
- // IMPORTANT vvvvvvvvvv
- // m = mon id;
- // c = position in party;
- // IMPORTANT ^^^^^^^^^^
- instance_create(x,y,Var);
- xview_offset = 0;
- yview_offset = 0;
- xoff = xview_offset;
- yoff = yview_offset;
- Bg = irandom_range(0,15);
- background_index = Bg;
- global.text_rand = 0;
- random_viewx = irandom_range(0,background_width-view_wview);
- random_viewy = irandom_range(0,background_height-view_hview);
- Max = keyboard_check(ord('M'));
- On = 0;
- aRandomPower = irandom_range(217,255); //set random power for specific moves
- bRandomPower = irandom_range(217,255); //set random power for specific moves
- VIS = 0;
- debugger = false;
- message_text = "";
- global.PlayerQueue = 0;
- global.Turn = 0;
- global.FinishedTurn = true;
- global.Player1Moving = false;
- global.Player2Moving = false;
- global.Player1DoneMoving = true;
- global.Player2DoneMoving = true;
- global.Player1Damaged = false;
- global.Player2Damaged = false;
- global.Player1TypeCalculated = false;
- global.Player2TypeCalculated = false;
- global.aHealth = 90;
- global.bHealth = 90;
- global.aDamageInflicted = 0;
- global.bDamageInflicted = 0;
- global.aWaiting = false;
- global.bWaiting = false;
- global.aFinishQueue = 0;
- global.bFinishQueue = 0;
- global.aSwitching = false;
- global.bSwitching = false;
- global.aFainted = false;
- global.bFainted = false;
- global.aFaintAction = false;
- global.bFaintAction = false;
- global.aComplexMove = false;
- global.bComplexMove = false;
- global.aMoveChosen = 0;
- global.bMoveChosen = 0;
- global.aCHitMod = 1;
- global.bCHitMod = 1;
- global.HoldOffNextMove = false;
- global.aSpecial = false;
- global.bSpecial = false;
- global.aMonPositioned = false;
- global.bMonPositioned = false;
- global.Manual = true;
- global.Player1Score = 0;
- global.Player2Score = 0;
- global.aDamageFrame = false;
- global.bDamageFrame = false;
- global.DamageFrame = 0;
- global.UseDamageFrames = false;
- global.MoveDelay = 0;
- global.MoveDelayAmount = 35; //this is manually adjusted for animations
- global.DelayMod = 10;
- global.SideBattleText = "([------TURN 0------])"+"##";
- global.aSideBattleText = "";
- global.bSideBattleText = "";
- SelectedMove = 0;
- OtherSelectedMove = 0;
- aSideName = "";
- bSideName = "";
- delay = 0;
- PreAttackDelay = 1;
- PostAttackDelay = 1;
- global.DamageFrameDelay = 0;
- global.BeginTurn = false;
- global.CoinToss = irandom_range(0,1);
- global.SpeedTied = false;
- global.aSpeedTieWin = false;
- global.bSpeedTieWin = false;
- global.aMoveTypeEffect = 1;
- global.bMoveTypeEffect = 1;
- global.TypeCalc = false;
- global.aMadPhase = false;
- global.bMadPhase = false;
- global.DamageActivateDelay = false;
- global.PlayHitSfx = false;
- global.CalcCrit = false;
- /// STAT MODIFIERS
- global.aStoredAtkMod = 1;
- global.aStoredDefMod = 1;
- global.aStoredSpAMod = 1;
- global.aStoredSpDMod = 1;
- global.aStoredSpeMod = 1;
- global.aStoredAccMod = 1;
- global.aStoredEvaMod = 1;
- global.bStoredAtkMod = 1;
- global.bStoredDefMod = 1;
- global.bStoredSpAMod = 1;
- global.bStoredSpDMod = 1;
- global.bStoredSpeMod = 1;
- global.bStoredAccMod = 1;
- global.bStoredEvaMod = 1;
- /// PERIPHERAL BATTLE EFFECTS (Weather, Terrain, Screens, Trick Room)
- // Weather
- global.Weather = "Normal"; // Normal, Rain, Sandstorm, Snow, Sunny
- global.WeatherTurns = 0;
- global.Terrain = "Normal"; // Ice, Fire, Wind, Electric, Mist, Grass, Weird
- global.TerrainTurns = 0;
- // Screens
- global.aLightScreen = 0;
- global.aReflectScreen = 0;
- global.bLightScreen = 0;
- global.bReflectScreen = 0;
- // Trick Room
- global.TrickRoom = 0;
- //
- mm = 0;
- /* PLAYER 1 MON ------------------------- */
- with(instance_create(x,view_yview+view_hview*0.6,Mon)) { /* PLAYER 1 MON ------------------------- */
- o = 0; // set mon to be player 1
- if global.monrandom = true {
- m = irandom_range(0,global.MonAmount-1); // for now we randomly select a mon
- }
- if global.monrandom = false {
- m = global.specific_mon_plyr1
- }
- image_index = m; //update sprite to appropriate mon
- // then we grab the corresponding stats for that mon
- aStoredPlyrName[m,c] = Var.NameId[m];
- aStoredPlyrHlth[m,c] = Var.HlthId[m]*2.2;
- aStoredPlyrHlthCache[m,c] = Var.HlthId[m]*2.2;
- aStoredPlyrAttk[m,c] = Var.AttkId[m];
- aStoredPlyrDfns[m,c] = Var.DfnsId[m];
- aStoredPlyrSpat[m,c] = Var.SpatId[m];
- aStoredPlyrSpdf[m,c] = Var.SpdfId[m];
- aStoredPlyrSped[m,c] = Var.SpedId[m];
- aStoredPlyrMove1[m,c] = irandom_range(0,global.Moves);
- aStoredPlyrMove2[m,c] = irandom_range(0,global.Moves);
- aStoredPlyrMove3[m,c] = irandom_range(0,global.Moves);
- aStoredPlyrMove4[m,c] = irandom_range(0,global.Moves);
- aStoredPlyrFaint[m,c] = false;
- // now we set our local stat variables to equal the stored data
- // PlyrName[0] = aStoredPlyrName[1,1] <-- Mon #1 in the 1st spot of your party
- global.aHealth = aStoredPlyrHlth[m,c];
- PlyrName[o] = aStoredPlyrName[m,c];
- PlyrHlth[o] = aStoredPlyrHlth[m,c];
- PlyrAttk[o] = aStoredPlyrAttk[m,c];
- PlyrDfns[o] = aStoredPlyrDfns[m,c];
- PlyrSpat[o] = aStoredPlyrSpat[m,c];
- PlyrSpdf[o] = aStoredPlyrSpdf[m,c];
- PlyrSped[0] = aStoredPlyrSped[m,c];
- aPlyrMove1 = aStoredPlyrMove1[m,c];
- aPlyrMove2 = aStoredPlyrMove2[m,c];
- aPlyrMove3 = aStoredPlyrMove3[m,c];
- aPlyrMove4 = aStoredPlyrMove4[m,c];
- }
- /* PLAYER 2 MON ------------------------- */
- with(instance_create(x,y,Mon)) { /* PLAYER 2 MON ------------------------- */
- o = 1; // set mon to be player 2
- if global.monrandom = true {
- m = irandom_range(0,global.MonAmount-1); // for now we randomly select a mon
- }
- if global.monrandom = false {
- m = global.specific_mon_plyr2
- }
- image_index = m; //update sprite to appropriate mon
- // then we grab the corresponding stats for that mon
- bStoredPlyrName[m,c] = Var.NameId[m];
- bStoredPlyrHlth[m,c] = Var.HlthId[m]*2.2;
- bStoredPlyrHlthCache[m,c] = Var.HlthId[m]*2.2;
- bStoredPlyrAttk[m,c] = Var.AttkId[m];
- bStoredPlyrDfns[m,c] = Var.DfnsId[m];
- bStoredPlyrSpat[m,c] = Var.SpatId[m];
- bStoredPlyrSpdf[m,c] = Var.SpdfId[m];
- bStoredPlyrSped[m,c] = Var.SpedId[m];
- bStoredPlyrMove1[m,c] = irandom_range(0,global.Moves);
- bStoredPlyrMove2[m,c] = irandom_range(0,global.Moves);
- bStoredPlyrMove3[m,c] = irandom_range(0,global.Moves);
- bStoredPlyrMove4[m,c] = irandom_range(0,global.Moves);
- bStoredPlyrFaint[m,c] = false;
- // now we set our local stat variables to equal the stored data
- //PlyrName[1] = bStoredPlyrName[1,1] <-- Mon #1 in the 1st spot of opponents party
- global.bHealth = bStoredPlyrHlth[m,c];
- PlyrName[o] = bStoredPlyrName[m,c];
- PlyrHlth[o] = bStoredPlyrHlth[m,c];
- PlyrAttk[o] = bStoredPlyrAttk[m,c];
- PlyrDfns[o] = bStoredPlyrDfns[m,c];
- PlyrSpat[o] = bStoredPlyrSpat[m,c];
- PlyrSpdf[o] = bStoredPlyrSpdf[m,c];
- PlyrSped[1] = bStoredPlyrSped[m,c];
- bPlyrMove1 = bStoredPlyrMove1[m,c];
- bPlyrMove2 = bStoredPlyrMove2[m,c];
- bPlyrMove3 = bStoredPlyrMove3[m,c];
- bPlyrMove4 = bStoredPlyrMove4[m,c];
- }
- Step Event:
- for other object: execute code:
- ///BATTLE INSTRUCTION
- xview_offset = random_viewx;
- yview_offset = random_viewy;
- background_x = view_xview-random_viewx;
- background_y = view_yview-random_viewy;
- if global.Player1Score >= 6 {
- global.battletext = "You lost.";
- audio_sound_gain(Var.Mus,0,0);
- room_goto(endroom);
- }
- if global.Player2Score >= 6 {
- global.battletext = "You won!";
- audio_sound_gain(Var.Mus,0,0);
- room_goto(endroom);
- }
- DFDelay = 3;
- if global.UseDamageFrames = true && global.MoveDelay < global.MoveDelayAmount {
- global.MoveDelay += 1;
- }
- if (global.UseDamageFrames = true && (global.DamageFrame < 6) && (global.MoveDelay >= global.MoveDelayAmount)) {
- if global.DamageFrameDelay <= DFDelay {
- global.DamageFrameDelay += 1;
- VIS = 0;
- }
- if global.DamageFrameDelay > DFDelay {
- if global.PlayHitSfx = false && global.MusicEnabled = 1 && global.Player1Moving = true && global.Player2Moving = false && global.aMoveTypeEffect >= 0.1 {
- if global.aMoveTypeEffect = 1 {
- if !audio_is_playing(Var.SndHit) {
- audio_play_sound(Var.SndHit,1,false);
- }
- }
- if global.aMoveTypeEffect < 1 && global.aMoveTypeEffect > 0 {
- if !audio_is_playing(Var.SndHitWeak) {
- audio_play_sound(Var.SndHitWeak,1,false);
- }
- }
- if global.aMoveTypeEffect >= 2 {
- if !audio_is_playing(Var.SndHitStrong) {
- audio_play_sound(Var.SndHitStrong,1,false);
- }
- }
- global.PlayHitSfx = true;
- }
- if global.PlayHitSfx = false && global.MusicEnabled = 1 && global.Player2Moving = true && global.Player1Moving = false && global.bMoveTypeEffect >= 0.1 {
- if global.bMoveTypeEffect = 1 {
- if !audio_is_playing(Var.SndHit) {
- audio_play_sound(Var.SndHit,1,false);
- }
- }
- if global.bMoveTypeEffect < 1 && global.bMoveTypeEffect > 0 {
- if !audio_is_playing(Var.SndHitWeak) {
- audio_play_sound(Var.SndHitWeak,1,false);
- }
- }
- if global.bMoveTypeEffect >= 2 {
- if !audio_is_playing(Var.SndHitStrong) {
- audio_play_sound(Var.SndHitStrong,1,false);
- }
- }
- global.PlayHitSfx = true;
- }
- if global.aDamageFrame = true && global.bDamageFrame = false && global.bMoveTypeEffect >= 0.1 {
- with(Mon) {
- if o = 0 && global.aMonPositioned = true {
- if visible = visible && other.VIS = 0 {
- visible = !visible;
- global.DamageFrame += 1;
- global.DamageFrameDelay = 0;
- other.VIS = 1;
- }
- if visible = !visible && global.DamageFrameDelay >= DFDelay+1 && other.VIS = 0 {
- visible = visible;
- global.DamageFrame += 1;
- global.DamageFrameDelay = 0;
- other.VIS = 1;
- }
- }
- }
- }
- if global.bDamageFrame = true && global.aDamageFrame = false && global.aMoveTypeEffect >= 0.1 {
- with(Mon) {
- if o = 1 && global.bMonPositioned = true {
- if visible = visible && other.VIS = 0 {
- visible = !visible;
- global.DamageFrame += 1;
- global.DamageFrameDelay = 0;
- other.VIS = 1;
- }
- if visible = !visible && global.DamageFrameDelay >= DFDelay+1 && other.VIS = 0 {
- visible = visible;
- global.DamageFrame += 1;
- global.DamageFrameDelay = 0;
- other.VIS = 1;
- }
- }
- }
- }
- if global.DamageFrame = 6 && global.DamageActivateDelay = false && PreAttackDelay < 0 {
- PreAttackDelay = 3;
- global.DamageActivateDelay = true;
- }
- }
- }
- if global.DamageFrame >= 6 && global.DamageActivateDelay = true && PreAttackDelay <= 0 {
- with(Mon) {
- visible = true;
- }
- global.aDamageFrame = false;
- global.bDamageFrame = false;
- global.DamageActivateDelay = false;
- }
- Mode = keyboard_check_pressed(vk_lshift);
- //toggle manual mode
- if Mode
- {
- if global.Manual = false then
- global.Manual = true;
- else
- global.Manual = false;
- }
- //same type attack bonus (STAB) calculation
- //adjust specific moves
- with(Mon) {
- if o = 0 && global.aWaiting = true && global.CalcCrit = false {
- if global.aMoveChosen = 73 || global.aMoveChosen = 86 || global.aMoveChosen = 89 || global.aMoveChosen = 90 || global.aMoveChosen = 94 || global.aMoveChosen = 98 || global.aMoveChosen = 101 || global.aMoveChosen = 109 || global.aMoveChosen = 110 || global.aMoveChosen = 118 || global.aMoveChosen = 119 || global.aMoveChosen = 120 {
- aCHitMod = choose(1,1,3,3,3);
- global.bCHitMod = choose(1,1,3,3,3);
- global.CalcCrit = true;
- }
- if global.aMoveChosen = 25 || global.aMoveChosen = 59 || global.aMoveChosen = 112 || global.aMoveChosen = 123 || global.aMoveChosen = 124 {
- aCHitMod = 3;
- }
- if global.aMoveChosen = 103 {
- aCHitMod = choose(1,3,4,3);
- global.CalcCrit = true;
- }
- if global.aMoveChosen = 99 {
- aCHitMod = choose(1,1,6,8,9,9,10);
- global.CalcCrit = true;
- }
- }
- if o = 1 && global.bWaiting = true && global.CalcCrit = false {
- if global.bMoveChosen = 73 || global.bMoveChosen = 86 || global.bMoveChosen = 89 || global.bMoveChosen = 90 || global.bMoveChosen = 94 || global.bMoveChosen = 98 || global.bMoveChosen = 101 || global.bMoveChosen = 109 || global.bMoveChosen = 110 || global.bMoveChosen = 118 || global.bMoveChosen = 119 || global.bMoveChosen = 120 {
- bCHitMod = choose(1,1,3,3,3);
- global.aCHitMod = bCHitMod;
- global.CalcCrit = true;
- }
- if global.bMoveChosen = 25 || global.bMoveChosen = 59 || global.bMoveChosen = 112 || global.bMoveChosen = 123 || global.bMoveChosen = 124 {
- bCHitMod = 3;
- }
- if global.bMoveChosen = 103 {
- bCHitMod = choose(1,3,4,3);
- global.CalcCrit = true;
- }
- if global.bMoveChosen = 99 {
- bCHitMod = choose(1,1,6,8,9,9,10);
- global.CalcCrit = true;
- }
- }
- }
- ///HANDLE ATTACKS QUEUE
- MonExists = instance_exists(Mon);
- xoff = xview_offset;
- yoff = yview_offset;
- Key = keyboard_check(ord('R'));
- MouseRight = mouse_check_button(mb_right);
- NoSound = keyboard_check_pressed(ord('S'));
- Shifty = keyboard_check(vk_lshift);
- if NoSound {
- if global.NoMusic = 0 {
- global.NoMusic = 1;
- } else {
- global.NoMusic = 0;
- }
- }
- if Key { game_restart(); }
- if MouseRight && Shifty { game_restart(); }
- if global.FinishedTurn = false {
- if PreAttackDelay > 0 { //if delay is greater than zero
- PreAttackDelay -= 0.2; //subtract 0.2
- }
- if PreAttackDelay <= 0 { //if delay is less than or equal to zero
- PreAttackDelay = -1; //set it to zero incase value goes less than zero
- }
- if PostAttackDelay > 0 { //if delay is greater than zero
- PostAttackDelay -= 0.2; //subtract 0.2
- }
- if PostAttackDelay <= 0 { //if delay is less than or equal to zero
- PostAttackDelay = -1; //set it to zero incase value goes less than zero
- }
- }
- //SET MESSAGE_TEXT TO ATTACK MESSAGES
- with(Mon) {
- if (o = 0 && global.aWaiting = false) {
- aRandomPower = irandom_range(217,255); //set random power for specific moves
- }
- if (o = 0 && aMoveSelected = true && global.aWaiting = false) {
- global.aWaiting = true;
- global.aCHitMod = choose(1,1,1,1,1,1,1,3,3); //critical hit chance
- switch(other.SelectedMove) {
- case 0:
- StoredText[0] = PlyrName[o]+" used "+string(Var.MoveName[aPlyrMove1])+"!";
- if Var.MoveCategory[aPlyrMove1] = "Physical" {
- global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrAttk*Var.MovePower[aPlyrMove1]/global.bStoredPlyrDfns/50+2*1*10/10*aRandomPower/255*global.aCHitMod;
- }
- if Var.MoveCategory[aPlyrMove1] = "Special" {
- global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrSpat*Var.MovePower[aPlyrMove1]/global.bStoredPlyrSpdf/50+2*1*10/10*aRandomPower/255*global.aCHitMod;
- }
- global.aMoveChosen = real(aPlyrMove1);
- //(Var.MovePower[aPlyrMove1]*(global.aStoredPlyrAttk/global.bStoredPlyrDfns))/50+2;
- break;
- case 1:
- StoredText[0] = PlyrName[o]+" used "+string(Var.MoveName[aPlyrMove2])+"!";
- if Var.MoveCategory[aPlyrMove2] = "Physical" {
- global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrAttk*Var.MovePower[aPlyrMove2]/global.bStoredPlyrDfns/50+2*1*10/10*aRandomPower/255*global.aCHitMod;
- }
- if Var.MoveCategory[aPlyrMove2] = "Special" {
- global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrSpat*Var.MovePower[aPlyrMove2]/global.bStoredPlyrSpdf/50+2*1*10/10*aRandomPower/255*global.aCHitMod;
- }
- //global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrAttk*Var.MovePower[aPlyrMove2]/global.bStoredPlyrDfns/50+2*1*10/10*aRandomPower/255;
- global.aMoveChosen = real(aPlyrMove2);
- break;
- case 2:
- StoredText[0] = PlyrName[o]+" used "+string(Var.MoveName[aPlyrMove3])+"!";
- if Var.MoveCategory[aPlyrMove3] = "Physical" {
- global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrAttk*Var.MovePower[aPlyrMove3]/global.bStoredPlyrDfns/50+2*1*10/10*aRandomPower/255*global.aCHitMod;
- }
- if Var.MoveCategory[aPlyrMove3] = "Special" {
- global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrSpat*Var.MovePower[aPlyrMove3]/global.bStoredPlyrSpdf/50+2*1*10/10*aRandomPower/255*global.aCHitMod;
- }
- //global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrAttk*Var.MovePower[aPlyrMove3]/global.bStoredPlyrDfns/50+2*1*10/10*aRandomPower/255;
- global.aMoveChosen = real(aPlyrMove3);
- break;
- case 3:
- StoredText[0] = PlyrName[o]+" used "+string(Var.MoveName[aPlyrMove4])+"!";
- if Var.MoveCategory[aPlyrMove4] = "Physical" {
- global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrAttk*Var.MovePower[aPlyrMove4]/global.bStoredPlyrDfns/50+2*1*10/10*aRandomPower/255*global.aCHitMod;
- }
- if Var.MoveCategory[aPlyrMove4] = "Special" {
- global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrSpat*Var.MovePower[aPlyrMove4]/global.bStoredPlyrSpdf/50+2*1*10/10*aRandomPower/255*global.aCHitMod;
- }
- //global.aDamageInflicted = ((200)/5+2)*global.aStoredPlyrAttk*Var.MovePower[aPlyrMove4]/global.bStoredPlyrDfns/50+2*1*10/10*aRandomPower/255;
- global.aMoveChosen = real(aPlyrMove4);
- break;
- }
- //global.PlayerQueue += 1;
- }
- if (o = 1 && global.bWaiting = false) {
- bRandomPower = irandom_range(217,255);
- }
- if o = 1 && bMoveSelected = true && global.bWaiting = false { //only updates the text for a moment
- global.bWaiting = true;
- global.bCHitMod = choose(1,1,1,1,1,1,1,3,3); //critical hit chance
- switch(other.OtherSelectedMove) {
- case 0:
- StoredText[1] = "The opposing "+PlyrName[o]+" used "+string(Var.MoveName[bPlyrMove1])+"!";
- if Var.MoveCategory[bPlyrMove1] = "Physical" {
- global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrAttk*Var.MovePower[bPlyrMove1]/global.aStoredPlyrDfns/50+2*1*10/10*bRandomPower/255*global.bCHitMod;
- }
- if Var.MoveCategory[bPlyrMove1] = "Special" {
- global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrSpat*Var.MovePower[bPlyrMove1]/global.aStoredPlyrSpdf/50+2*1*10/10*bRandomPower/255*global.bCHitMod;
- }
- //global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrAttk*Var.MovePower[bPlyrMove1]/global.aStoredPlyrDfns/50+2*1*10/10*bRandomPower/255;
- global.bMoveChosen = real(bPlyrMove1);
- break;
- case 1:
- StoredText[1] = "The opposing "+PlyrName[o]+" used "+string(Var.MoveName[bPlyrMove2])+"!";
- if Var.MoveCategory[bPlyrMove2] = "Physical" {
- global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrAttk*Var.MovePower[bPlyrMove2]/global.aStoredPlyrDfns/50+2*1*10/10*bRandomPower/255*global.bCHitMod;
- }
- if Var.MoveCategory[bPlyrMove2] = "Special" {
- global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrSpat*Var.MovePower[bPlyrMove2]/global.aStoredPlyrSpdf/50+2*1*10/10*bRandomPower/255*global.bCHitMod;
- }
- //global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrAttk*Var.MovePower[bPlyrMove2]/global.aStoredPlyrDfns/50+2*1*10/10*bRandomPower/255;
- global.bMoveChosen = real(bPlyrMove2);
- break;
- case 2:
- StoredText[1] = "The opposing "+PlyrName[o]+" used "+string(Var.MoveName[bPlyrMove3])+"!";
- if Var.MoveCategory[bPlyrMove3] = "Physical" {
- global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrAttk*Var.MovePower[bPlyrMove3]/global.aStoredPlyrDfns/50+2*1*10/10*bRandomPower/255*global.bCHitMod;
- }
- if Var.MoveCategory[bPlyrMove3] = "Special" {
- global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrSpat*Var.MovePower[bPlyrMove3]/global.aStoredPlyrSpdf/50+2*1*10/10*bRandomPower/255*global.bCHitMod;
- }
- //global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrAttk*Var.MovePower[bPlyrMove3]/global.aStoredPlyrDfns/50+2*1*10/10*bRandomPower/255;
- global.bMoveChosen = real(bPlyrMove3);
- break;
- case 3:
- StoredText[1] = "The opposing "+PlyrName[o]+" used "+string(Var.MoveName[bPlyrMove4])+"!";
- if Var.MoveCategory[bPlyrMove4] = "Physical" {
- global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrAttk*Var.MovePower[bPlyrMove4]/global.aStoredPlyrDfns/50+2*1*10/10*bRandomPower/255*global.bCHitMod;
- }
- if Var.MoveCategory[bPlyrMove4] = "Special" {
- global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrSpat*Var.MovePower[bPlyrMove4]/global.aStoredPlyrSpdf/50+2*1*10/10*bRandomPower/255*global.bCHitMod;
- }
- //global.bDamageInflicted = ((200)/5+2)*global.bStoredPlyrAttk*Var.MovePower[bPlyrMove4]/global.aStoredPlyrDfns/50+2*1*10/10*bRandomPower/255;
- global.bMoveChosen = real(bPlyrMove4);
- break;
- }
- //global.PlayerQueue += 1;
- }
- }
- //BEGIN ATTACKING ONCE EVERYONE HAS SELECTED A MOVE
- //DETERMINE WHO IS FASTER FIRST TO BUILD A QUEUE
- if (global.PlayerQueue >= 2) {
- global.FinishedTurn = false; //allows text box to fire off attack cmds
- //TYPE EFFECTIVENESS CALCULATION
- /*
- if global.TypeCalc = false {
- defender_type_matchup_plyr1_type1();
- defender_type_matchup_plyr2_type1();
- global.TypeCalc = true;
- }
- */
- //check 'o' value of Mon object and see who is faster
- with(Mon) {
- if (o = 0) { // player 1 moves
- if ((global.aStoredPlyrSped*Var.MovePriority[global.aMoveChosen] > global.bStoredPlyrSped)
- || global.bFinishQueue = 1
- || global.aSpeedTieWin = true) /*if faster or player 2 already moved*/
- {
- if (global.Player1Moving = false && global.Player2Moving = false && aMoveSelected = true && bMoveSelected = true && global.aFinishQueue = 0) {
- global.Player1Moving = true;
- global.Player1DoneMoving = false;
- other.PreAttackDelay = 5; // Waits before hp starts depleting (where move animations and damage effect takes place)
- global.MoveDelay = 0;
- global.CalcCrit = false;
- global.BeginTurn = true;
- other.message_text = StoredText[0]; // "Player used Move!"
- global.SideBattleText += string(StoredText[0])+"##";
- defender_type_matchup_plyr2_type1();
- // STAB calculation
- if (global.aStoredPlyrType1 = Var.MoveType[global.aMoveChosen]
- || global.aStoredPlyrType2 = Var.MoveType[global.aMoveChosen]) {
- global.aDamageInflicted *= 1.5;
- }
- }
- }
- }
- if (o = 0 && other.PreAttackDelay = -1 && global.bDamageFrame = false && global.Player1Moving = true && global.Player1DoneMoving = false) {
- global.Player2Damaged = true;
- global.UseDamageFrames = true;
- global.bDamageFrame = true;
- }
- }
- with(Mon) {
- if (o = 1) { // player 2 moves
- if ((global.aStoredPlyrSped <= global.bStoredPlyrSped*Var.MovePriority[global.bMoveChosen])
- || global.aFinishQueue = 1
- || global.bSpeedTieWin = true) //if faster or player 1 already moved
- {
- if (global.Player2Moving = false && global.Player1Moving = false && aMoveSelected = true && bMoveSelected = true && global.bFinishQueue = 0) {
- global.Player2Moving = true; // player 2 moves, damages player 1
- global.Player2DoneMoving = false;
- other.PreAttackDelay = 5; // Waits before hp starts depleting (where move animations and damage effect takes place)
- global.MoveDelay = 0;
- global.CalcCrit = false;
- global.BeginTurn = true;
- other.message_text = StoredText[1]; // "The opposing Player used Move!"
- global.SideBattleText += string(StoredText[1])+"##";
- defender_type_matchup_plyr1_type1();
- // STAB calculation
- if (global.bStoredPlyrType1 = Var.MoveType[global.bMoveChosen]
- || global.bStoredPlyrType2 = Var.MoveType[global.bMoveChosen]) {
- global.bDamageInflicted *= 1.5;
- }
- }
- }
- }
- if (o = 1 && other.PreAttackDelay = -1 && global.aDamageFrame = false && global.Player2Moving = true && global.Player2DoneMoving = false) {
- global.Player1Damaged = true;
- global.UseDamageFrames = true;
- global.aDamageFrame = true;
- }
- }
- }
- if (MonExists) //finish the turn
- if (PreAttackDelay < 1 && global.aFinishQueue = 1 && global.bFinishQueue = 1 && global.FinishedTurn = false) {
- global.FinishedTurn = true; //finish the turn
- global.PlayerQueue = 0;
- global.Player1Moving = false;
- global.Player2Moving = false;
- global.Player1Damaged = false;
- global.Player2Damaged = false;
- global.Player1DoneMoving = true;
- global.Player2DoneMoving = true;
- global.aDamageInflicted = 0;
- global.bDamageInflicted = 0;
- global.aWaiting = 0;
- global.bWaiting = 0;
- global.aComplexMove = false;
- global.bComplexMove = false;
- OtherSelectedMove = irandom_range(0,3);
- if global.Manual = false {
- SelectedMove = irandom_range(0,3);
- }
- global.HoldOffNextMove = false;
- global.Player1TypeCalculated = false;
- global.Player2TypeCalculated = false;
- global.aMoveTypeEffect = 1;
- global.bMoveTypeEffect = 1;
- global.TypeCalc = false;
- global.DamageFrame = 0;
- global.aDamageFrame = false;
- global.bDamageFrame = false;
- global.UseDamageFrames = false;
- global.PlayHitSfx = false;
- global.MoveDelay = 0;
- global.DamageFrameDelay = 0;
- with(Mon) {
- aMoveSelected = false;
- bMoveSelected = false;
- aCrit = false;
- bCrit = false;
- aRandomPower = irandom_range(217,255); //set random power for specific moves
- bRandomPower = irandom_range(217,255); //set random power for specific moves
- }
- global.aFinishQueue = 0;
- global.bFinishQueue = 0;
- global.Turn += 1;
- global.SideBattleText += "([------TURN "+string(global.Turn)+"------])"+"##";
- random_viewx = irandom_range(0,room_width-view_wview);
- random_viewy = irandom_range(0,room_height-view_hview);
- Bg = irandom_range(0,15);
- background_index = Bg;
- if global.aStoredPlyrSped = global.bStoredPlyrSped {
- global.CoinToss = irandom_range(0,1);
- global.SpeedTied = true;
- }
- if global.aStoredPlyrSped != global.bStoredPlyrSped {
- global.SpeedTied = false;
- global.aSpeedTieWin = false;
- global.bSpeedTieWin = false;
- }
- if global.SpeedTied = true {
- switch(global.CoinToss) {
- case 0: global.aSpeedTieWin = true; global.bSpeedTieWin = false; break;
- case 1: global.bSpeedTieWin = true; global.aSpeedTieWin = false; break;
- }
- }
- }
- if global.FinishedTurn = true && global.aFinishQueue = 0 && global.bFinishQueue = 0 {
- message_text = "What will "+string(aSideName)+" do?";
- global.BeginTurn = true;
- }
- //if global.Manual = false && global.FinishedTurn = true && global.PlayerQueue = 0 {
- //global.PlayerQueue = 4;
- //}
- execute code:
- ///SWITCHING OUT POKEMON
- /* PLAYER 1 MON ------------------------- */
- if global.aSwitching = true && global.aFaintAction = true && global.aFainted = true {
- PreAttackDelay = 10;
- mm = irandom_range(0,global.MonAmount-1);
- switch(global.text_rand) {
- case 0: message_text = "Go! "+string(Var.NameId[mm])+"!"; break;
- case 1: message_text = "Im counting on you "+string(Var.NameId[mm])+"!"; break;
- case 2: message_text = "Take charge! "+string(Var.NameId[mm])+"!"; break;
- case 3: message_text = "Lets finish this "+string(Var.NameId[mm])+"!"; break;
- case 4: message_text = "You got this in the bag "+string(Var.NameId[mm])+"!"; break;
- case 5: message_text = "Pull off something great! "+string(Var.NameId[mm])+"!"; break;
- case 6: message_text = "Im counting on you "+string(Var.NameId[mm])+"!"; break;
- case 7: message_text = "Be your very best! "+string(Var.NameId[mm])+"!"; break;
- case 8: message_text = "Take it back! "+string(Var.NameId[mm])+"!"; break;
- }
- global.SideBattleText += string(message_text)+"##";
- global.aFainted = false;
- global.aMadPhase = false;
- }
- if PreAttackDelay < 1 && global.aSwitching = true && global.aFainted = false {
- with(instance_create(view_xview+view_wview*0.2,view_yview+view_hview*0.6,Mon)) { /* PLAYER 1 MON ------------------------- */
- o = 0; // set mon to be player 1
- m = other.mm; // for now we randomly select a mon
- image_index = m; // update sprite to appropriate mon
- if global.MusicEnabled = 1 {
- audio_play_sound(Var.SndSwitch,1,false);
- }
- // then we grab the corresponding stats for that mon
- aStoredPlyrName[m,c] = Var.NameId[m];
- aStoredPlyrHlth[m,c] = Var.HlthId[m]*2.2;
- aStoredPlyrHlthCache[m,c] = Var.HlthId[m]*2.2;
- aStoredPlyrAttk[m,c] = Var.AttkId[m];
- aStoredPlyrDfns[m,c] = Var.DfnsId[m];
- aStoredPlyrSpat[m,c] = Var.SpatId[m];
- aStoredPlyrSpdf[m,c] = Var.SpdfId[m];
- aStoredPlyrSped[m,c] = Var.SpedId[m];
- aStoredPlyrMove1[m,c] = irandom_range(0,global.Moves);
- aStoredPlyrMove2[m,c] = irandom_range(0,global.Moves);
- aStoredPlyrMove3[m,c] = irandom_range(0,global.Moves);
- aStoredPlyrMove4[m,c] = irandom_range(0,global.Moves);
- aStoredPlyrFaint[m,c] = false;
- // now we set our local stat variables to equal the stored data
- // PlyrName[0] = aStoredPlyrName[1,1] <-- Mon #1 in the 1st spot of your party
- global.aHealth = aStoredPlyrHlth[m,c];
- PlyrName[o] = aStoredPlyrName[m,c];
- PlyrHlth[o] = aStoredPlyrHlth[m,c];
- PlyrAttk[o] = aStoredPlyrAttk[m,c];
- PlyrDfns[o] = aStoredPlyrDfns[m,c];
- PlyrSpat[o] = aStoredPlyrSpat[m,c];
- PlyrSpdf[o] = aStoredPlyrSpdf[m,c];
- PlyrSped[0] = aStoredPlyrSped[m,c];
- aPlyrMove1 = aStoredPlyrMove1[m,c];
- aPlyrMove2 = aStoredPlyrMove2[m,c];
- aPlyrMove3 = aStoredPlyrMove3[m,c];
- aPlyrMove4 = aStoredPlyrMove4[m,c];
- other.PreAttackDelay = 10;
- global.aSwitching = false;
- global.aFaintAction = false;
- global.aFinishQueue = 1;
- global.text_rand = irandom(8);
- }
- }
- /* PLAYER 2 MON ------------------------- */
- if global.bSwitching = true && global.bFaintAction = true && global.bFainted = true {
- PreAttackDelay = 10;
- global.bFainted = false;
- global.bMadPhase = false;
- mm = irandom_range(0,global.MonAmount-1);
- message_text = "The opponent sent out "+string(Var.NameId[mm])+"!";
- global.SideBattleText += string(message_text)+"##";
- }
- if PreAttackDelay < 1 && global.bSwitching = true && global.bFainted = false {
- with(instance_create(view_xview-2000,view_yview-600,Mon)) { /* PLAYER 2 MON ------------------------- */
- o = 1; // set mon to be player 2
- m = other.mm; // for now we randomly select a mon
- image_index = m; // update sprite to appropriate mon
- if global.MusicEnabled = 1 {
- audio_play_sound(Var.SndSwitch,1,false);
- }
- // then we grab the corresponding stats for that mon
- bStoredPlyrName[m,c] = Var.NameId[m];
- bStoredPlyrHlth[m,c] = Var.HlthId[m]*2.2;
- bStoredPlyrHlthCache[m,c] = Var.HlthId[m]*2.2;
- bStoredPlyrAttk[m,c] = Var.AttkId[m];
- bStoredPlyrDfns[m,c] = Var.DfnsId[m];
- bStoredPlyrSpat[m,c] = Var.SpatId[m];
- bStoredPlyrSpdf[m,c] = Var.SpdfId[m];
- bStoredPlyrSped[m,c] = Var.SpedId[m];
- bStoredPlyrMove1[m,c] = irandom_range(0,global.Moves);
- bStoredPlyrMove2[m,c] = irandom_range(0,global.Moves);
- bStoredPlyrMove3[m,c] = irandom_range(0,global.Moves);
- bStoredPlyrMove4[m,c] = irandom_range(0,global.Moves);
- bStoredPlyrFaint[m,c] = false;
- // now we set our local stat variables to equal the stored data
- //PlyrName[1] = bStoredPlyrName[1,1] <-- Mon #1 in the 1st spot of opponents party
- global.bHealth = bStoredPlyrHlth[m,c];
- PlyrName[o] = bStoredPlyrName[m,c];
- PlyrHlth[o] = bStoredPlyrHlth[m,c];
- PlyrAttk[o] = bStoredPlyrAttk[m,c];
- PlyrDfns[o] = bStoredPlyrDfns[m,c];
- PlyrSpat[o] = bStoredPlyrSpat[m,c];
- PlyrSpdf[o] = bStoredPlyrSpdf[m,c];
- PlyrSped[1] = bStoredPlyrSped[m,c];
- bPlyrMove1 = bStoredPlyrMove1[m,c];
- bPlyrMove2 = bStoredPlyrMove2[m,c];
- bPlyrMove3 = bStoredPlyrMove3[m,c];
- bPlyrMove4 = bStoredPlyrMove4[m,c];
- other.PreAttackDelay = 10;
- global.bSwitching = false;
- global.bFaintAction = false;
- global.bFinishQueue = 1;
- }
- }
- execute code:
- ///MISCELLANEOUS
- Click = mouse_check_button_pressed(mb_left);
- rClickHold = mouse_check_button(mb_right);
- lClickHold = mouse_check_button(mb_left);
- Enter = keyboard_check(vk_enter);
- if (Enter && lClickHold && rClickHold) {
- room_goto(debugroom);
- }
- Max = keyboard_check_pressed(ord('M'));
- Sfx = keyboard_check_pressed(ord('N'));
- if Max
- {
- if window_get_fullscreen()=0 then
- window_set_fullscreen(true)
- else
- window_set_fullscreen(false)
- }
- if Sfx {
- if global.MusicEnabled = 1 {
- global.MusicEnabled = 0;
- } else {
- global.MusicEnabled = 1;
- }
- }
- if global.MusicEnabled = 0
- {
- //audio_stop_all();
- }
- Draw Event:
- execute code:
- ///DRAW EVENT
- /*
- x1y1====================================
- ========================================
- ========================================
- ====================================x2y2
- */
- draw_set_font(font0);
- padding = 32;
- box_height = 128;
- textcolor = c_black;
- textboxcolor = c_white;
- mainCol = make_colour_rgb(80, 191, 29);
- mainCol2 = make_colour_rgb(30, 145, 212);
- text_draw(view_xview+4,view_yview+16,"P1: "+string(global.Player1Score),c_white)
- text_draw(view_xview+4,view_yview+38,"P2: "+string(global.Player2Score),c_white)
- box_left = view_xview+padding;
- box_top = view_yview+view_hview-padding-box_height;
- box_right = view_xview+view_wview-padding;
- box_bottom = view_yview+view_hview-padding;
- with(Mon) {
- if o = 0 {
- other.aSideName = PlyrName[0];
- }
- if o = 1 {
- other.bSideName = PlyrName[1];
- }
- }
- draw_set_color(textboxcolor);
- draw_set_alpha(0.82);
- draw_rectangle(box_left,box_top,box_right,box_bottom,false);
- draw_set_alpha(1);
- // display text message
- draw_set_font(minecraftia);
- text_draw(box_left*1.3,box_top*1.01,string(message_text),textcolor);
- draw_set_font(font0);
- Left = keyboard_check_pressed(vk_left);
- Right = keyboard_check_pressed(vk_right);
- Up = keyboard_check_pressed(vk_up);
- Down = keyboard_check_pressed(vk_down);
- ScrollUp = mouse_wheel_up();
- ScrollDown = mouse_wheel_down();
- Select = keyboard_check_pressed(vk_enter);
- MouseSelect = mouse_check_button_pressed(mb_left);
- XMouseSelect = mouse_check_button(mb_left);
- pQ = keyboard_check_pressed(ord('Q'));
- maxStringWidth = "ThisIsTheMaxStringLimit";
- longestString = string_width(maxStringWidth);
- mainTextCol = mainCol;
- mainTextCol2 = mainCol2;
- if Var.MoveCategory[global.aStoredPlyrMove1] == "Physical" && SelectedMove != 0 {
- MoveColor1 = mainTextCol;
- }
- if Var.MoveCategory[global.aStoredPlyrMove1] == "Special" && SelectedMove != 0 {
- MoveColor1 = mainTextCol2;
- }
- if Var.MoveCategory[global.aStoredPlyrMove2] == "Physical" && SelectedMove != 1 {
- MoveColor2 = mainTextCol;
- }
- if Var.MoveCategory[global.aStoredPlyrMove2] == "Special" && SelectedMove != 1 {
- MoveColor2 = mainTextCol2;
- }
- if Var.MoveCategory[global.aStoredPlyrMove3] == "Physical" && SelectedMove != 2 {
- MoveColor3 = mainTextCol;
- }
- if Var.MoveCategory[global.aStoredPlyrMove3] == "Special" && SelectedMove != 2 {
- MoveColor3 = mainTextCol2;
- }
- if Var.MoveCategory[global.aStoredPlyrMove4] == "Physical" && SelectedMove != 3 {
- MoveColor4 = mainTextCol;
- }
- if Var.MoveCategory[global.aStoredPlyrMove4] == "Special" && SelectedMove != 3 {
- MoveColor4 = mainTextCol2;
- }
- /* Moves
- 0 | 1
- -----------
- 2 | 3
- */
- if delay > 0 {
- delay -= 0.2;
- }
- audio_sound_pitch(select,1);
- if global.aWaiting = false {
- if (Left && delay = 0)
- if (SelectedMove = 1 || SelectedMove = 3) {
- SelectedMove -= 1;
- delay = 0.6;
- play_select();
- }
- if (Left && delay = 0)
- if (SelectedMove = 0 || SelectedMove = 2) {
- SelectedMove += 1;
- delay = 0.6;
- play_select();
- }
- if (Right && delay = 0)
- if (SelectedMove = 0 || SelectedMove = 2) {
- SelectedMove += 1;
- delay = 0.6;
- play_select();
- }
- if (Right && delay = 0)
- if (SelectedMove = 1 || SelectedMove = 3) {
- SelectedMove -= 1;
- delay = 0.6;
- play_select();
- }
- if (Up && delay = 0)
- if (SelectedMove = 2 || SelectedMove = 3) {
- SelectedMove -= 2;
- delay = 0.6;
- play_select();
- }
- if (Up && delay = 0)
- if (SelectedMove = 0 || SelectedMove = 1) {
- SelectedMove += 2;
- delay = 0.6;
- play_select();
- }
- if (Down && delay = 0)
- if (SelectedMove = 0 || SelectedMove = 1) {
- SelectedMove += 2;
- delay = 0.6;
- play_select();
- }
- if (Down && delay = 0)
- if (SelectedMove = 2 || SelectedMove = 3) {
- SelectedMove -= 2;
- delay = 0.6;
- play_select();
- }
- if (ScrollDown && delay = 0) {
- if SelectedMove < 3 {
- SelectedMove += 1;
- delay = 0.6;
- } else {
- SelectedMove = 0;
- delay = 0.6;
- }
- }
- if (ScrollUp && delay = 0) {
- if SelectedMove > 0 {
- SelectedMove -= 1;
- delay = 0.6;
- } else {
- SelectedMove = 3;
- delay = 0.6;
- }
- }
- }
- switch(SelectedMove) {
- case 0:
- MoveColor1 = c_yellow;
- break;
- case 1:
- MoveColor2 = c_yellow;
- break;
- case 2:
- MoveColor3 = c_yellow;
- break;
- case 3:
- MoveColor4 = c_yellow;
- }
- if (pQ) {
- if (debugger)
- debugger = false;
- else
- debugger = true;
- }
- if debugger = true {
- //text_draw(box_left*1.3,box_top*0.90,"Player Queue: "+string(global.PlayerQueue),mainTextCol);
- //text_draw(box_left*1.3,box_top*0.85,"bSelected: "+string(Mon.bMoveSelected),mainTextCol);
- //text_draw(box_left*1.3,box_top*0.80,"aSelected: "+string(Mon.aMoveSelected),mainTextCol);
- //text_draw(box_left*1.3,box_top*0.70,"bMoving: "+string(global.Player2Moving),mainTextCol);
- //text_draw(box_left*1.3,box_top*0.65,"aMoving: "+string(global.Player1Moving),mainTextCol);
- //text_draw(box_left*1.3,box_top*0.70,"bDamageInflicted: "+string(global.bDamageInflicted),mainTextCol);
- //text_draw(box_left*1.3,box_top*0.65,"aDamageInflicted: "+string(global.aDamageInflicted),mainTextCol);
- //text_draw(box_left*1.3,box_top*0.75,"FinishedTurn: "+string(global.FinishedTurn),mainTextCol);
- //text_draw(box_left*1.3,box_top*0.85,"PreAttackDelay: "+string(PreAttackDelay),mainTextCol);
- //text_draw(box_left*1.3,box_top*0.80,"Text Rand: "+string(global.text_rand),mainTextCol);
- if XMouseSelect {
- text_draw(mouse_x,mouse_y,"x: "+string(mouse_x)+"#y: "+string(mouse_y),c_yellow);
- }
- }
- with(Mon) {
- if global.Manual = true && aMoveSelected = false
- if (other.Select = true || other.MouseSelect = true) {
- if !audio_is_playing(select) && aMoveSelected = false {
- play_select();
- }
- aMoveSelected = true;
- global.PlayerQueue += 1;
- if bMoveSelected = false {
- bMoveSelected = true;
- global.PlayerQueue += 1;
- }
- //global.PlayerQueue += 1;
- }
- }
- with(Mon) {
- if global.Manual = false && aMoveSelected = false {
- //if !audio_is_playing(select) && aMoveSelected = false {
- //play_select();
- //aMoveSelected = true;
- //}
- SelectedMove = irandom_range(0,3);
- aMoveSelected = true;
- global.PlayerQueue += 1;
- if bMoveSelected = false {
- bMoveSelected = true;
- global.PlayerQueue += 1;
- }
- //global.PlayerQueue += 1;
- }
- }
- // display the movepool
- draw_set_font(minecraftia);
- PadOffset = 1.75;
- Pad2Offset = 1.90;
- VerBoxOffset = 1.10;
- VBO2 = 0.08;
- if global.aWaiting = false {
- text_draw(box_right-(longestString*2)-(padding*PadOffset),box_top*VerBoxOffset,string(Var.MoveName[global.aStoredPlyrMove1])+" ("+string(Var.MoveType[global.aStoredPlyrMove1])+" "+string(Var.MovePower[global.aStoredPlyrMove1])+")",MoveColor1);
- text_draw(box_right-(padding*Pad2Offset)-string_width("("+string(Var.MovePower[global.aStoredPlyrMove2])+" "+string(Var.MoveType[global.aStoredPlyrMove2])+") "+string(Var.MoveName[global.aStoredPlyrMove2]))+24,box_top*VerBoxOffset,"("+string(Var.MovePower[global.aStoredPlyrMove2])+" "+string(Var.MoveType[global.aStoredPlyrMove2])+") "+string(Var.MoveName[global.aStoredPlyrMove2]),MoveColor2);
- text_draw(box_right-(longestString*2)-(padding*PadOffset),box_top*(VerBoxOffset+VBO2),string(Var.MoveName[global.aStoredPlyrMove3])+" ("+string(Var.MoveType[global.aStoredPlyrMove3])+" "+string(Var.MovePower[global.aStoredPlyrMove3])+")",MoveColor3);
- text_draw(box_right-(padding*Pad2Offset)-string_width("("+string(Var.MovePower[global.aStoredPlyrMove4])+" "+string(Var.MoveType[global.aStoredPlyrMove4])+") "+string(Var.MoveName[global.aStoredPlyrMove4]))+24,box_top*(VerBoxOffset+VBO2),"("+string(Var.MovePower[global.aStoredPlyrMove4])+" "+string(Var.MoveType[global.aStoredPlyrMove4])+") "+string(Var.MoveName[global.aStoredPlyrMove4]),MoveColor4);
- }
- /*
- box_left = view_xview+padding;
- box_top = view_yview+view_hview-padding-box_height;
- box_right = view_xview+view_wview-padding;
- box_bottom = view_yview+view_hview-padding;
- */
- draw_set_font(font0);
Add Comment
Please, Sign In to add comment