| 1 |
function scr_determine_attacking_damage_stat_criticalscr_determine_attacking_damage_stat_criticalfunction scr_determine_attacking_damage_stat_critical()
{
var player_weapon = global.player_weapon;
var player_weapon_modifier = global.player_weapon_modifier;
var enemy_count = global.enemy_count;
switch (player_weapon)
{
case "Toy Gun":
switch (player_weapon_modifier)
{
case "Pebble Ammo":
case "Cff Bean Ammo":
case "Glass Ammo":
case "Super Ammo":
case "Silver Ammo":
var hit_count = 1;
break;
case "Ice Pellets":
var hit_count = 2;
break;
case "Flint":
case "Friendliness Pellets":
case "Nails":
var hit_count = 3;
break;
default:
var hit_count = 1;
}
global.attacking_damage_stat_critical = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat) + 2) * 2.5);
if (enemy_count >= 2)
global.attacking_damage_stat_critical_2 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_2) + 2) * 2.5);
if (enemy_count >= 3)
global.attacking_damage_stat_critical_3 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_3) + 2) * 2.5);
break;
case "Wild Revolver":
switch (player_weapon_modifier)
{
case "Pebble Ammo":
case "Cff Bean Ammo":
case "Glass Ammo":
case "Super Ammo":
case "Silver Ammo":
var hit_count = 1;
break;
case "Ice Pellets":
var hit_count = 2;
break;
case "Flint":
case "Friendliness Pellets":
case "Nails":
var hit_count = 3;
break;
default:
var hit_count = 1;
}
global.attacking_damage_stat_critical = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat) + 2) * 3.5);
if (enemy_count >= 2)
global.attacking_damage_stat_critical_2 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_2) + 2) * 3.5);
if (enemy_count >= 3)
global.attacking_damage_stat_critical_3 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_3) + 2) * 3.5);
break;
default:
global.attacking_damage_stat_critical = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat) + 2) * 2.5);
if (enemy_count >= 2)
global.attacking_damage_stat_critical_2 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_2) + 2) * 2.5);
if (enemy_count >= 3)
global.attacking_damage_stat_critical_3 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_3) + 2) * 2.5);
}
} () |
| 2 |
{ |
| 3 |
var player_weapon = global.player_weapon; |
| 4 |
var player_weapon_modifier = global.player_weapon_modifier; |
| 5 |
var enemy_count = global.enemy_count; |
| 6 |
switch (player_weapon) |
| 7 |
{ |
| 8 |
case "Toy Gun": |
| 9 |
switch (player_weapon_modifier) |
| 10 |
{ |
| 11 |
case "Pebble Ammo": |
| 12 |
case "Cff Bean Ammo": |
| 13 |
case "Glass Ammo": |
| 14 |
case "Super Ammo": |
| 15 |
case "Silver Ammo": |
| 16 |
var hit_count = 1; |
| 17 |
break; |
| 18 |
case "Ice Pellets": |
| 19 |
var hit_count = 2; |
| 20 |
break; |
| 21 |
case "Flint": |
| 22 |
case "Friendliness Pellets": |
| 23 |
case "Nails": |
| 24 |
var hit_count = 3; |
| 25 |
break; |
| 26 |
default: |
| 27 |
var hit_count = 1; |
| 28 |
} |
| 29 |
global.attacking_damage_stat_critical = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat) + 2) * 2.5); |
| 30 |
if (enemy_count >= 2) |
| 31 |
global.attacking_damage_stat_critical_2 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_2) + 2) * 2.5); |
| 32 |
if (enemy_count >= 3) |
| 33 |
global.attacking_damage_stat_critical_3 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_3) + 2) * 2.5); |
| 34 |
break; |
| 35 |
case "Wild Revolver": |
| 36 |
switch (player_weapon_modifier) |
| 37 |
{ |
| 38 |
case "Pebble Ammo": |
| 39 |
case "Cff Bean Ammo": |
| 40 |
case "Glass Ammo": |
| 41 |
case "Super Ammo": |
| 42 |
case "Silver Ammo": |
| 43 |
var hit_count = 1; |
| 44 |
break; |
| 45 |
case "Ice Pellets": |
| 46 |
var hit_count = 2; |
| 47 |
break; |
| 48 |
case "Flint": |
| 49 |
case "Friendliness Pellets": |
| 50 |
case "Nails": |
| 51 |
var hit_count = 3; |
| 52 |
break; |
| 53 |
default: |
| 54 |
var hit_count = 1; |
| 55 |
} |
| 56 |
global.attacking_damage_stat_critical = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat) + 2) * 3.5); |
| 57 |
if (enemy_count >= 2) |
| 58 |
global.attacking_damage_stat_critical_2 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_2) + 2) * 3.5); |
| 59 |
if (enemy_count >= 3) |
| 60 |
global.attacking_damage_stat_critical_3 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_3) + 2) * 3.5); |
| 61 |
break; |
| 62 |
default: |
| 63 |
global.attacking_damage_stat_critical = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat) + 2) * 2.5); |
| 64 |
if (enemy_count >= 2) |
| 65 |
global.attacking_damage_stat_critical_2 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_2) + 2) * 2.5); |
| 66 |
if (enemy_count >= 3) |
| 67 |
global.attacking_damage_stat_critical_3 = round((((global.player_weapon_attack + global.player_weapon_modifier_attack + global.player_attack) - global.enemy_defense_stat_3) + 2) * 2.5); |
| 68 |
} |
| 69 |
} |