Depends on your game version (1.29, 1.31, latest, etc) and whether you use GUI/Jass/Lua.
There's this save/load system for Jass + GUI users, which is almost guaranteed to be you if you're unsure:
Information If you've ever wanted to transfer progress between multiplayer maps, you probably needed to type in a long code. That is no longer needed with this system. This will allow you to read save data from your WC3 folder and sync it to all other players in the map. The demo map...
www.hiveworkshop.com
And here's a link to a "barebones" version I made of the above system.
Note that I can't promise that either of these still work:
I have been searching for a save/load system for my RPG for some time now, trying different ones but none that really fits or im too much of a noob to edit them to work xD Preferably it should save to a file so you dont need to write it down by yourself. The codeless one is cool in here but...
www.hiveworkshop.com
This system in particular can only save Integers, and I think that's the case for basically every Jass save/load system. But an Integer can be used to represent anything you want, so you aren't all that limited if you're clever about it.
Now understand that these systems don't let you LITERALLY save a Hero. Instead, you save all of the details about that Hero, like their Unit-Type, their current Level, their current Experience, each Item-Type they have equipped, and so on. Then you rebuild that Hero upon Loading by creating a new Hero, creating and giving them copies of their old Items, and adding Exp / setting their Level.
For example, if you wanted to Save someone's Hero you would Save the
[index] of a Unit-Type Array which points to the type of Hero they're using:
-
Set Variable HeroType[1] = Paladin
-
Set Variable HeroType[2] = Archmage
-
Set Variable HeroType[3] = Mountain King
So by Saving the number
2 you'd be Saving the fact that they're playing as the
Archmage since that Hero is stored at index
[2].
Also, note that you Save things in a precise order (1 = Hero, 2 = Level, 3 = Exp) and you Load things following that same order. This is how you can map your loaded Integers back to their associated Arrays. Although, in the case of TriggerHappy's system the Loading process is done in reverse order. It's a little confusing but you just have to think in reverse, Exp -> Level -> Hero.
I don't feel like going into much greater detail since I've posted this information in many other threads but that's the gist of it.