Transponder code changes

So, I went for a flight in the DoubleEnder over Ontario Canada, and got a CTD over CYOW. I didn’t check the transponder code in the DoubleEnder. Then I launched a flight in the YMF-5 from CYYJ, and I notice my transponder is set to 7000 when it should be 1200. Does this code get set by plane or airport? I always test in the YMF-5, so it’s unusual for the transponder to switch to 7000 in Canada. Does anyone know how that could get muddled up?

I believe it’s set by the plane. 7000 is the ICAO and EASA VFR transponder code

It is used in the UK and most non North American countries!

Yes, but this was a flight launched in Canada. I wonder where the plane picks up the location. Is this from rolling cache? or from the streaming server?

It depends entirely on the plane. Some planes are hardcoded to only default to a single code, usually 7000 or 2000, and others will attempt to default to 1200 or 7000 depending on where you begin your flight. It’s up to each developer on what they want to do.

I’m not familiar with this specific aircraft so I’m not sure what its specific defaults are.

The YMF-5 is launching with 1200 in CYYJ Victoria, BC Canada now. I am assuming it gets persisted somewhere.