Welcome to Smogon! Take a moment to read the Introduction to Smogon for a run-down on everything Smogon, and make sure you take some time to read the global rules.
This version has more substantial code changes, but it will let you choose which gimmick to prioritize, (all mons can dynamax** and tera, but are each limited to one gimmick). Posted an image of how it would work. Should be easy enough to tweak to force only 1 gimmick each or prioritize certain...
Yes, this is on the same mon. You would set your list of preference for each mon in the team builder. In this scenario, you would always have a valid tera type chosen, so the tiebreaker is decided by the what was set in the team builder.
You mentioned the following earlier.
The logic could be...
Actually have a version where you can do all of them assuming there is a priority selection list in team builder. (No longer need to select 'None' as a tera type)
For example, if you have a rayquaza with dragon ascent and a flying z-crystal with priority (Tera -> Dynamax -> Z-move -> Mega)...
Having issues with git/github, so just in case, I'm posting the patches here.
Current implementation, bugs notwithstanding, is the following
You can select 'None' as a tera type in the teambuilder when in a natdex format.
In battle
You cannot tera/dynamax if you have the option to mega...
Currently unable to. If it's something everybody agrees should be a thing, then I can try looking into it.
Edit: You can dynamax a pokemon with a tera type if you have already tera'd a different pokemon. Easy enough to turn on/off the implementation.
The reverse might be a little tricky to...
I think I got tera and dynamax working together. The way I have it setup currently is setting a tera type to "None" or some other invalid type will let you dynamax. Mons with valid teras cannot dynamax. Still working out some issues like should primals be allowed to tera?