I have been trying to figure out how to divide a room into areas. Currently I want to make a sports field. Here is what I have come up with so far:
[rant][code]modify Platform
dobjFor(Enter) asDobjFor(StandOn)
connectorStagingLocation
{
return gActor.roomLocation.ofKind(Platform);
}
canObjReachSelf(obj)
{
return obj.roomLocation.ofKind(Platform) && gActor.posture == standing;
}
;
field: Room ‘Field’
desc = "This is the field. "
;
- homeSide: Platform ‘home side’ ‘home side’
;
++ me: Actor
;
- visitorSide: Platform ‘visitor side’ ‘visitor side’
;[/code][/rant]
And here is my transcript:
[rant]Field (standing on the home side)
This is the field.
You see a visitor side and a home side here.
enter visitor side
(first getting off of the home side)
Okay, you’re now standing on the visitor side.
leave
(off of the visitor side)
Okay, you’re no longer on the visitor side.
enter home side
Okay, you’re now standing on the home side.[/rant]
For the most part my areas do what I want them to do, but as the transcript shows there are two problems with what I have coded so far. The first is that I would prefer to replace the line first getting off of the home side with something more natural (e.g. first leaving the home side). Second, I do not want to let the PC leave the visitor side without making her enter the home side (or vice versa). While I would appreciate suggestions on how to modify my current code to avoid these two problems, I think it’s probably first worth asking this: Am I going about this all wrong? It seems that both problems are the logical consequences of trying to push platforms into service to do something they were never intended to do. Have I been overlooking a better way to create areas of the sort I am envisioning?