aspace-sim / aspace

ASpace space simulator for the PennMUSH MU* Server
11 stars 6 forks source link

[Softcode] Bug in Admin Commands - C_SPACE_MAKECON #3

Closed DieterKoblenz closed 7 years ago

DieterKoblenz commented 10 years ago

With C_SPACE_MAKECON you can add extra consoles to a ship (Using @space/makecon "name")

Doing this however clears the &CONSOLES var on the ship object and only adds the newly created consoledb#. This prevents at least "TEXT" to function properly.

&C_SPACE_MAKECON Wizard Zone=$@SPACE/makecon *:th setq(9,create(%0)) tel(%q9,loc(%#))][set(%q9,Wizard)];@swi [t(match(%q9,locate(%#,secure(%q9),*)))][orflags(%#,W)][orflags(%q9,W)][hastype(loc(%q9),R)][orflags(zone(loc(%q9)),+)][gt(get(zone(loc(%q9))/SDB),0)]=10????,{@pem %#=Permission denied.},110???,{@pem %#=[v(NAME)] needs a Wizard bit.},1110??,{@pem %#=[name(loc(%q9))] is not a room.},11110?,{@pem %#=[name(zone(loc(%q9)))] is not a space object.},111110,{@pem %#=[name(zone(loc(%q9)))] has no SDB number.},111111,{@set %q9=safe;@set %q9=!no_command;@set %q9=monitor;@lock %q9=%q9;@lock/use %q9=%q9;@lock/zone %q9=%q9;@lock/enter %q9=%q9;@link %q9=loc(%q9);@parent %q9=xget(#13,PARENT_OFF);&SDB %q9=get(zone(loc(%q9))/SDB);&SHIP %q9=zone(loc(%q9));&NAME %q9=name(%q9);&CONSOLES zone(loc(%q9))=squish(iter(setunion(get(zone(loc(%q9))/CONSOLES),%q9),if(and(match(lparent(##),#13),match(get(##/SHIP),get(%q9/SHIP))),##)));&MODES %q9=command communications engineering helm inactive monitor navigation off operations science security tactical transporter weapons damage fighter;@pem %#=Installing [xget(%q9,NAME)].}

mike347 commented 7 years ago

Not sure why this was never closed, but it has been fixed. Thanks!