You need to edit the User data In the data folder (screenshot 1 to 3)
After that you need to have unlock blue shards(from buying in shop) and purple shards by clearing maps, you will receive 1 or 2 purple. You cannot edit if you don't receive those first (screenshot 4)
For editing: look for the shard line as in picture, and you can see the UID of each shard, green first , then blue, then purple(if unlocked 5th screenshot) same for gold shard. In the 6th , it's the coded value that I copied and pasted on the green shards UID. Save it and restart the game. Screenshot 7.
If you wanna edit your troupes value, go line 14 ,just add numbers you want, the units sitting from left to write in barracks will get the value you set. Screenshots 8,9,10