How to activate a gameobject with a trigger?

Googmorning,
I’m trying to create a script that shows me immediately after entering play mode 3 images and that activates other images only if some objects inside the scene are activated for the first time. Unfortunately the code I’m using is not able to activate the images after some gameobjects are activated for the first time, could someone help me figure out what’s wrong?

You cannot use Invoke to start a coroutine - you need to use StartCorourine instead:

StartCorourine(WaitBeforeShow2());

I tried but in this way the functions starts together, and WaitBeforeShow2 does not start with the trigger.

What do you mean by “trigger” in this context? I don’t understand.

From what your Start method looks like, do you mean you just want to delay the execution of WaitBeforeShow2 by 2 seconds?
If so, you can do that by just adding another WaitForSeconds at the very beginning of it:

public IEnumerator WaitBeforeShow2()
{
  //Immediately wait for 2 seconds after starting this coroutine.
  yield return new WaitForSeconds(2f);

  //Do everything else afterwards.
}

Or add the delay as a parameter so that you can specify it from when you call it in Start:

void Start()
{
  StartCorourine(WaitBeforeShow());
  StartCorourine(WaitBeforeShow2(2f));
}

public IEnumerator WaitBeforeShow2(float delay)
{
  //Immediately wait for the delay after starting this coroutine.
  yield return new WaitForSeconds(delay);

  //Do everything else afterwards.
}