Author Topic: Regenmap implementation  (Read 2179 times)

Regenmap implementation
« on: May 04, 2016, 08:55:26 pm »
Is there a way to implement the regenmap command scriptwise? And if it's possible, how would I do that?

Re: Regenmap implementation
« Reply #1 on: May 05, 2016, 10:27:42 am »
Yes you can, just do these simple steps

First you write a parser to read the location.cfg to find the map's file name via Map::GetProtoId
Then you write a parser to read the map.fomap

Then you use your favourite Map::GetItem of choice and delete everything
Do that for critters too

Remember that fomap you parsed? Well time to place some critters and items back on the map yo.

If a script is attached to the fomap and you want to run that again, Map::SetScript that shit

Optionally Map::SetData 0 to 99 to whatever default value you choose or not at all!

Or you can try Map::Reload