Difference between revisions of "Conn/exits"
Jump to navigation
Jump to search
Line 1: | Line 1: | ||
− | <pre>@ExitFormat here=Trods:%r%t[trim(iter(lexits(me),if(get(##/trod),[setq(0, name(##))[index(%q0,:,2,2) <[index(%q0,:,1,1)]>]])))]%rDuelling Rings:%r%t[iter(lexits(me),if(not(get(##/trod)), [setq(0, name(##))[index(%q0,:,2,2) <[index(%q0,:,1,1)]>]]))]</pre> | + | <pre>@ExitFormat here=Trods:%r%t[trim(iter(lexits(me),if(get(##/trod),[setq(0, name(##))[index(%q0,:,2,2) <%xh[index(%q0,:,1,1)]%xn>]])))]%rDuelling Rings:%r%t[iter(lexits(me),if(not(get(##/trod)), [setq(0, name(##))[index(%q0,:,2,2) <%xh[index(%q0,:,1,1)]%xn>]]))]</pre> |
Latest revision as of 10:16, 5 May 2021
@ExitFormat here=Trods:%r%t[trim(iter(lexits(me),if(get(##/trod),[setq(0, name(##))[index(%q0,:,2,2) <%xh[index(%q0,:,1,1)]%xn>]])))]%rDuelling Rings:%r%t[iter(lexits(me),if(not(get(##/trod)), [setq(0, name(##))[index(%q0,:,2,2) <%xh[index(%q0,:,1,1)]%xn>]]))]
Okay, gonna try to explain this bit by bit.
@exitformat allows you to, for any room you own, list the ones that are trods on a different line than the ones that aren't.
It does this by looping through the exits in a room and, if the exit has had the property TROD, listing it in the first iter, and if it doesn't, listing it on the second.
You can change trod to any property you like, as long as it matches what's set in the get(##/trod).