Skip to content
View in the app

A better way to browse. Learn more.

The AVSIM Community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

CASE statement

Featured Replies

And me again. I tried using a case statement in my script, eg:

30·20·10·3·(L:XMLVAR_BoostFuelPump,·number)·case·(>L:DEADBEEF)

I would expect it to be something along the lines like this

switch XMLVAR_BoostFuelPump {

case 0:

DEADBEEF = 10

case 1:

DEADBEEF = 20

case 2:

DEADBEEF = 30

}

This works quite well for XMLVAR_BoostFuelPump 1 and 2, if it is 0 however, I get 0 returned, not 10. What am I doing wrong? From reading the SDK documentation the syntax should be correct.

[values] [# of cases] Variable case

 

any help is appreciated

  • Commercial Member
20 hours ago, Deimos said:

This works quite well for XMLVAR_BoostFuelPump 1 and 2, if it is 0 however, I get 0 returned, not 10. What am I doing wrong? From reading the SDK documentation the syntax should be correct.

[values] [# of cases] Variable case

 

any help is appreciated

That is a bug. Will be corrected in 2.09. 

LORBY-SI

  • Author

Awesome, thank you very much for the swift reply and the workaround. Work held me up today, but I will have a look at it this weekend 🙂

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.