If the creature loses flying before Shadow Puppeteers's last ability resolves, the creature will still become a red Dragon with base power and toughness 4/4 in addition to its other colors and types until end of turn. It won't gain flying.
Shadow Puppeteers
If the creature stops being a creature before Shadow Puppeteers's last ability resolves, it will become red until end of turn in addition to its other colors. Since it's not a creature, it won't gain the Dragon subtype, and it won't have base power and toughness 4/4.
Shadow Puppeteers's last ability overwrites any previous effects that set the creature's power and/or toughness to specific values. Any power- or toughness-setting effects that start to apply after Shadow Puppeteers's last ability resolves will overwrite this effect.
Magic: The Gathering · ™ & © Wizards of the Coast · Illus. Cristi Balanescu
Card data via Scryfall. Rarix is fan-made; not endorsed by the rights holders.
