Skip to content

Commit 7666246

Browse files
committed
update name
1 parent dab9a41 commit 7666246

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

code/ai/aicode.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9065,7 +9065,7 @@ void ai_chase()
90659065
}
90669066
}
90679067

9068-
if (timestamp_elapsed(swp->next_secondary_fire_stamp[current_bank]) && weapon_allowed_lock_restriction_object(swip, En_objp)) {
9068+
if (timestamp_elapsed(swp->next_secondary_fire_stamp[current_bank]) && weapon_target_satisfies_lock_restrictions(swip, En_objp)) {
90699069
if (current_bank >= 0) {
90709070
float firing_range;
90719071

code/hud/hudlock.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -924,7 +924,7 @@ void hud_lock_acquire_uncaged_target(lock_info *current_lock, weapon_info *wip)
924924
continue;
925925
}*/
926926

927-
if (!weapon_allowed_lock_restriction_object(wip, A)) {
927+
if (!weapon_target_satisfies_lock_restrictions(wip, A)) {
928928
continue;
929929
}
930930

@@ -1042,7 +1042,7 @@ void hud_lock_determine_lock_target(lock_info *lock_slot, weapon_info *wip)
10421042
return;
10431043
}
10441044

1045-
if ( !weapon_allowed_lock_restriction_object(wip, lock_slot->obj) ) {
1045+
if ( !weapon_target_satisfies_lock_restrictions(wip, lock_slot->obj) ) {
10461046
ship_clear_lock(lock_slot);
10471047
return;
10481048
}
@@ -1110,7 +1110,7 @@ void hud_lock_determine_lock_target(lock_info *lock_slot, weapon_info *wip)
11101110
return;
11111111
}
11121112

1113-
if ( !weapon_allowed_lock_restriction_object(wip, lock_slot->obj) ) {
1113+
if ( !weapon_target_satisfies_lock_restrictions(wip, lock_slot->obj) ) {
11141114
ship_clear_lock(lock_slot);
11151115
return;
11161116
}

code/weapon/weapon.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -677,7 +677,7 @@ void shield_impact_explosion(vec3d *hitpos, object *objp, float radius, int idx)
677677
int weapon_get_max_missile_seekers(weapon_info *wip);
678678

679679
// return if this weapon can lock on this target, based on its type, class, species or iff
680-
bool weapon_allowed_lock_restriction_object(weapon_info *wip, object* target);
680+
bool weapon_target_satisfies_lock_restrictions(weapon_info *wip, object* target);
681681

682682
// return if this weapon has iff restrictions, and should ignore normal iff targeting restrictions
683683
bool weapon_has_iff_restrictions(weapon_info* wip);

code/weapon/weapons.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4094,7 +4094,7 @@ void find_homing_object(object *weapon_objp, int num)
40944094

40954095
homing_object_team = obj_team(objp);
40964096
bool can_attack = weapon_has_iff_restrictions(wip) || iff_x_attacks_y(wp->team, homing_object_team);
4097-
if (weapon_allowed_lock_restriction_object(wip, objp) && can_attack)
4097+
if (weapon_target_satisfies_lock_restrictions(wip, objp) && can_attack)
40984098
{
40994099
if ( objp->type == OBJ_SHIP )
41004100
{
@@ -5376,7 +5376,7 @@ void weapon_set_tracking_info(int weapon_objnum, int parent_objnum, int target_o
53765376
targeting_same = 0;
53775377
}
53785378

5379-
bool can_lock = (weapon_has_iff_restrictions(wip) && target_objnum >= 0) ? weapon_allowed_lock_restriction_object(wip, &Objects[target_objnum]) :
5379+
bool can_lock = (weapon_has_iff_restrictions(wip) && target_objnum >= 0) ? weapon_target_satisfies_lock_restrictions(wip, &Objects[target_objnum]) :
53805380
(!targeting_same || (MULTI_DOGFIGHT && (target_team == Iff_traitor)));
53815381

53825382
// Cyborg17 - exclude all invalid object numbers here since in multi, the lock slots can get out of sync.
@@ -8686,7 +8686,7 @@ int weapon_get_max_missile_seekers(weapon_info *wip)
86868686
}
86878687

86888688
// returns whether a homing weapon can home on a particular ship
8689-
bool weapon_allowed_lock_restriction_object(weapon_info* wip, object* target)
8689+
bool weapon_target_satisfies_lock_restrictions(weapon_info* wip, object* target)
86908690
{
86918691
if (target->type != OBJ_SHIP)
86928692
return true;

0 commit comments

Comments
 (0)