ID:166739
 
Well, not really. They only pose a minor threat, consisting mostly of headaches.

Is there a way to create new areas at runtime that aren't connected others of their type already placed? It states in the reference that "Additional instances of rooms may be created from the same type by explicitly creating them with null as the initial location. That is, the first argument to new() should either be null or left unspecified. " However, that doesn't help me because I need them on the map, and an area's location is constant.

I tried using tags hoping it would take care of it, but it didn't work:
mob
icon = 'T.dmi'
verb
Create1() new/area/Dynamic(null,loc,1)
Create2() new/area/Dynamic(null,loc,2)
Create3() new/area/Dynamic(null,loc,3)
Create4() new/area/Dynamic(null,loc,4)
Create5() new/area/Dynamic(null,loc,5)

area
Dynamic
icon = 'Colors.dmi'
layer=7
New(M,L,N)
flick("[N]",src)
tag = "[N]"
loc=L
Entered()
icon_state = tag
world<<tag
sleep(5)
icon_state = null


Just a little test I tried, and failed, rather miserably.

Does anyone know of a method to do this?
Does an area have a loc itself, or do you add turfs to areas?

(Not sure since I haven't played with areas in forever)
In response to Jon88
"For areas, this value is always null, since an area may not be contained by any other object. "

It's the lowest level on the map, I believe. The map contains areas. Areas contain turfs, turfs contain movable atoms.
In response to DarkCampainger
You can manually add turfs to the area's contents list.
dynamic_area.contents.Add(some_turf)
//or
some_turf.loc = dynamic_area
In response to IainPeregrine
Thanks a ton! You just saved me atleast two days ^_^

This should be documented in the help file, I didn't even know that was possible :p

Although, knowing that's possible now, I can somewhat see what areas really are.

Thanks again!
In response to IainPeregrine
Ungh! No use Add() when single item!