Defining a scoring volume in the tracking world

In the Book For Application Developers there is this passage:(4.9.2)

Scoring volume can be declared as a logical volume that is already defined as a part of the mass geometry through /score/create/realWorldLogVol <LV_name> <anc_lvl> command, where <LV_name> is the name of G4LogicalVolume defined in the tracking world. If there are more than one physical volumes that share the same logical volume, scores are made for each individual physical volumes separately. Copy number of the physical volume is the index. If the physical volume is placed only once in its mother volume, but its (grand-)mother volume is duplicated, use the <anc_lvl> parameter to indicate the ancestor level where the copy number should be taken as the index of the score.

How can I achieve:“If there are more than one physical volumes that share the same logical volume, scores are made for each individual physical volumes separately. Copy number of the physical volume is the index.” Are there any examples to learn from?

I look forward to and thank you for your reply.

Example (G4VUserDetectorConstruction class):

    G4Box *Box = new G4Box("SomeBox", 5.*mm, 5.*mm, 5.*mm);
    G4LogicalVolume *l_Box = new G4LogicalVolume(Box, someMaterial, "SomeBox");
    // first physical volume, co
    new G4PVPlacement(nullptr,
                      G4ThreeVector(0,0,0),
                      l_Box,
                      "Box 1",
                      fWorldVolume,
                      false,
                      0); // this is the copy number, 0
    // second physical volume, attached to the same logical volume
    new G4PVPlacement(nullptr,
                      G4ThreeVector(0,0,20)*mm,
                      l_Box,
                      "Box 2",
                      fWorldVolume,
                      false,
                      1); // this is the copy number, 1

/score/create/realWorldLogVol someBox will give you entries for copy number 0 and 1 individually.
(and I think, /score/create/realWorldLogVol someBox 1 will use the mother volume’s copy number, which is 0, as it is the world volume for both)

I see. Thank you very much for your answer