Page 1 of 1

Zone Lock/Unlock implemented

Posted: Sat Jul 28, 2012 9:08 pm
by John Adams
Quite by accident, I wound up on this path. I was attempting to add functionality to kill a crashed zone (brutally) from the console, and in the learning process on how to do that I figured out how to add the ability for a GM to "lock" a zone. This will come in handy later when access to a zone requires some quest or key.

The new in-game command is:

Code: Select all

/zone lock [zone_id | name]
/zone unlock [zone_id | name]
If the zone is locked, players cannot /zone into it. They will get a message that the zone is locked, and they do not have the key.

If the zone is not running, you should not be able to lock it (not a DB value, only dynamic). This is where I am stuck. I cannot seem to access the zone I want, instead it only accesses the last zone I was in. Trying to use zone_list.Get(id, false), and it's not fetching "id" but current.

Also, something else I failed to figure out, I wanted a Console Command for "zone active" to list active zones. However, I cannot seem to access a public list of zones currently loaded. Need help with that.

Committed, and should be crashless ;)