is it possible to execute different scenarios in a simulation depending on an if statement?

I am running many different scenarios concurrently in my simulation.
I’d like to add an option in Jenkins to choose which scenarios will be executed concurrently, so my first thought was a
simulation code that looks as follows but setUp only accepts a Simulation class which I am not sure how tif there is a way
to input in such manner (Apologies for my lousy Scala skills) Is it supposed to be possible? or maybe another way to go about this?

setUp(
if(isScenario1){
scenario1.inject(rampConcurrentUsers(1) to 1000 during (Config.rampUpDuration minutes))
      .protocols(rest_httpconf),
    *scenario12*.inject(rampConcurrentUsers(1) to 1000 during (Config.rampUpDuration minutes))
      .protocols(rest_httpconf),
    *scenario13*.inject(rampConcurrentUsers(1) to 1000 during (Config.rampUpDuration minutes))
      .protocols(rest_httpconf),
  }
if (isScenario2){
scenario2.inject(rampConcurrentUsers(1) to 1000 during (Config.rampUpDuration minutes))
      .protocols(option_httpconf),
    scenario22.inject(rampConcurrentUsers(1) to 1000 during (Config.rampUpDuration minutes))
      .protocols(option_httpconf),
    scenario23.inject(rampConcurrentUsers(1) to 1000 during (Config.rampUpDuration minutes))
      .protocols(option_httpconf),
    }
  if(*isScenario3*){{
  scenario3.inject(rampConcurrentUsers(1) to 1000 during (Config.rampUpDuration minutes))
    .protocols(option_httpconf)
}
  if(isScenario4){
scenario4.inject(rampConcurrentUsers(1) to 1000 during (Config.rampUpDuration minutes))
    .protocols(rest_httpconf)
}
).maxDuration(Config.scenarioDuration minutes).assertions(global.successfulRequests.percent.is(98))

I think this is more of a Jenkins question than a Gatling one. It won’t work in Jenkins as far as I know because Jenkins just executes a given script or scripts based on conditions.
I am not sure how to do that; maybe contact your Jenkins admin for advice?

Hi Mishal and thanks for your reply.
It actually doesn’t matter if you run it through Jenkins or through your IDE, all Jenkins does is executing the test and passing
command line arguments, in our case the the Booleans you see in my example.

If anyone is interested, the solution is here