Hi David, hoping you can point me in the right direction. I have decided not to bother moving via scriptcards for Thunderwave and will just click n drag, but I wanted to automate things a bit more by deducting spell slot. Took your Thunderwave SmartAoE and stuffed it into a SC. Works perfectly in the sandpit but when I add it to the current game it starts the process (rolls damage, subtracts spell slot) but then Smart AoE puts a chat message of "SmartAoE:You must either select a token or pass the tokenID via --selected|ID". I don't get why the same character transmogrified across gets a different result based on which game it is in? Your SmartAoE works in both. This is what I have:
!script {{
+++dnd5elib+++
--#hideCard|
--=Level|?{Cast at what level?|1,1|2,2|3,3|4,4|5,5|6,6|7,7|8,8|9,9}
--=dice|[$Level]+1
--=damage|[$dice]d8
--+DMG|[$damage]
-->Lib5E_DeductSpellSlot|@{selected|character_id};[$Level]
--@smartaoe|
_title|Thunderwave
_leftsub|Cast at Level[$Level]
_rightsub|DC @{selected|spell_save_dc} CON
_titlecardbackground|url('
https://s3.amazonaws.com/files.d20.io/images/253624290/aHQ8iSGWD1gYyR94kocxOg/max.png?1635893578');background-size: 100% 100%; background-repeat: no-repeat
_subtitlefontcolor|#ffffff
_aoeColor|#88888850
_aoeOutlineColor|#ffffff
_aoeType|square, float
_forceIntersection|0
_offset|1,0
_radius|7.5ft
_fx|burn-smoke
_dc|@{selected|spell_save_dc}
_saveFormula|5eCON
_damageFormula1|[$damage]
_damageType1|Thunder
_instant|1
_ignore|SmartAoE_Ignore,1
_autoApply|1
_bar|1
_zeroHPmarker|dead
_desc|A wave of thunderous force sweeps out from you. Each creature in a 15-foot cube originating from you must make a Constitution saving throw. On a failed save, a creature takes [$damage] thunder damage and is pushed 10 feet away from you. On a successful save, the creature takes half as much damage and isn't pushed.%br%In addition, unsecured objects that are completely within the area of effect are automatically pushed 10 feet away from you by the spell's effect, and the spell emits a thunderous boom audible out to 300 feet.
}}