arduino laser harp code issue

Hello all ,I am working on a laser harp for a university assignment however I have came across an issue I believe my physical setup is correct but the code I am not the best with can anyone help me figure out why when the laser or light is put on the photo resistors it makes a noise rather than when the laser is broken it should make the noise.

#include <Tone.h>

const boolean DEBUG = false;

const int CALIBRATION_PIN = A5;
const int SPEAKER_PIN = 8;
const int SENSOR_COUNT = 3;

typedef struct 
{
  int pin;
  int note;
} sensor_type;

sensor_type sensor[SENSOR_COUNT];

Tone notePlayer;

void setup(void)
{
  if (DEBUG) {
    Serial.begin(9600);
  }
  sensor[0].pin = A0; // analog input 0, etc...
  sensor[0].note = NOTE_G3;
  sensor[1].pin = A1;
  sensor[1].note = NOTE_D4;
  sensor[2].pin = A2;
  sensor[2].note = NOTE_A4;
  
  notePlayer.begin(SPEAKER_PIN);
}

void loop(void)
{
  int calibration = analogRead(CALIBRATION_PIN);
  if (DEBUG) {
    Serial.print("cal: ");
    Serial.print(calibration);
  }
  int activeSensor = -1;
  for (int p = 0 ; p < SENSOR_COUNT ; p++) {
    int sensor_value = analogRead(sensor[p].pin);
    if (DEBUG) {
      Serial.print("\tsensor ");
      Serial.print(p);
      Serial.print(": ");
      Serial.print(sensor_value);
    }
    if ( sensor_value < calibration ) {
      activeSensor = p;
      if (DEBUG) Serial.print("!"); // "!" indicates note being played
    }
  }
  if (DEBUG) Serial.println();
  if (activeSensor == -1) {
    notePlayer.stop();
  } else {
    notePlayer.play(sensor[activeSensor].note);
  }
  if (DEBUG) delay(1000);
}

What does your debug output show?

Why is calibration done in loop()? Calibration is a one-time thing, not an every pass through loop thing.

cal: 576    sensor 0: 946   sensor 1: 920   sensor 2: 923
cal: 577    sensor 0: 945   sensor 1: 916   sensor 2: 922
cal: 577    sensor 0: 435!  sensor 1: 919   sensor 2: 919
cal: 577    sensor 0: 544!  sensor 1: 919   sensor 2: 922
cal: 577    sensor 0: 948   sensor 1: 451!  sensor 2: 921
cal: 577    sensor 0: 946   sensor 1: 911   sensor 2: 746
cal: 577    sensor 0: 947   sensor 1: 921   sensor 2: 269!
cal: 577    sensor 0: 942   sensor 1: 729   sensor 2: 916
cal: 578    sensor 0: 947   sensor 1: 390!  sensor 2: 922
cal: 577    sensor 0: 538!  sensor 1: 917   sensor 2: 922
cal: 577    sensor 0: 948   sensor 1: 921   sensor 2: 925
cal: 577    sensor 0: 949   sensor 1: 922   sensor 2: 927
cal: 577    sensor 0: 949   sensor 1: 922   sensor 2: 927
cal: 577    sensor 0: 949   sensor 1: 922   sensor 2: 927

the ! indicates that that sensor has the laser shun into it and is beeping but what I want eventually is all 3 sensors to have lasers on them but only to beep once the laser is broken.

The sound happens when the sensor value is one side of the calibration value. If you want it to happen when the sensor value is on the other side, turn the > around.

at which part sorry I am very new to the coding?

at which part?

    if ( sensor_value < calibration ) {

thats great got it working thank you!