"A dump of #4489 on Sun Dec 17 12:57:22 1995 PST @create $thing named LRPG Recycler:LRPG Recycler,LRPGR,recycler @prop #4489."rotten" {} r ;;#4489.("rotten") = {{#80026, {{#80026, "rot", #2693, #2803, #60470}, {#15458, "rot_corpse", #2693, #259, #60470}, {#15458, "duty", #2693, #259, #60470}, {#15458, "duty", #19845, #48119, #60470}, {#15458, "birth", #2693, #259, #60470}, {#15458, "birth", #19845, #48119, #60470}, {#15458, "die", #2693, #259, #60470}}}} @prop #4489."summarize_task" 1491950988 r ;;#4489.("key") = 0 ;;#4489.("aliases") = {"LRPG Recycler", "LRPGR", "recycler"} ;;#4489.("description") = "A chugging mass of wires and pistons, throwing sparks and belching mechanical grunts of displeasure with the LambdaMOO Quota System." ;;#4489.("object_size") = {5728, 819192795} @verb #4489:"ok_to_recycle" this none this rx @program #4489:ok_to_recycle ":ok_to_recycle(object)"; "Return false if the object has verbs or properties defined, or kids."; "This recycler is intended for public use, and the public has no cause to recycle developed G_M-owned objects."; o = args[1]; return !((children(o) || verbs(o)) || properties(o)); . @verb #4489:"_recycle" this none this @program #4489:_recycle ":_recycle(object) - Pass to $recycler if perms are secure."; o = args[1]; if (!this:trust_to_recycle(caller_perms(), o)) return E_PERM; endif if (!this:ok_to_recycle(o)) return E_NACC; endif $command_utils:suspend_if_needed(0); recycled = $recycler:_recycle(o); if (o in this.owner.owned_objects) this.rotten = {@this.rotten, {o, callers()}}; endif return recycled; "DR 08-MAY-95 -- Changed to pass obj to trust_to_recycle."; "GMs are allowed to recycle killable things using this verb now."; "Slither 6/7/95 -- Added suspend_if_needed call"; . @verb #4489:"_create" this none this rx @program #4489:_create ":_create(parent-object[, announce-to])"; "Pass to $recycler if perms are secure. If E_QUOTA is returned, find the bad object in our .owned_objects and re-recycle it."; "If announce-to is given, tell that player when we suspend."; if (!this:trust_to_create(caller_perms())) return E_PERM; endif o = args[1]; $command_utils:suspend_if_needed(0); if ((o.owner != this.owner) && (!o.f)) o:make_fertile(); elseif (((o.owner == this.owner) && (!(o in {#46.doll, #46.corpse}))) && (!(o in $local.rpg.grabber.dispenses))) this.owner:report_error("~recyler: making child of non-dispensed object. Callers: " + $string_utils:print(callers())); endif created = $recycler:_create(o); if (created != E_QUOTA) return created; endif if (!$code_utils:task_valid(this.summarize_task)) this.summarize_task = task_id(); for o in (this.owner.owned_objects) if ($command_utils:suspend_if_needed(0, "~recycler:_create() suspending...")) player:tell("~recycler:_create() resuming..."); endif if ((typeof(o.object_size) == ERR) && $recycler:valid(o)) this.owner:report_error(((("~recycler -> " + tostr(this)) + ":_recycle(") + tostr(o)) + ");"); this:_recycle(o); endif endfor "Last attempt at trying to fixie the problem."; $quota_utils:summarize_one_user(this.owner, -1); if ((o.owner != this.owner) && (!o.f)) o:make_fertile(); endif return $recycler:_create(o); else player:tell("Grand_Master is in the process of attempting to compensate for a $recycler bug. Please be patient and hold off playing for a bit."); return E_QUOTA; endif "Quinn 11-May-94: Added summarize_task so as not to over-burden the MOO with multiple surveys."; "Quinn 11-May-94: If we can't create using the preferred $recycler method, do a raw create and return that."; "08-NOV-94 DR: Reinstated above hacks, just return errors when summarize_task is running, no raw create (will not work)."; "Profane 16-MAR-95 12:47EST - Added :make_fertile() calls, mostly so #259:check_mine() calls don't bomb out on non-G_M owned equipment."; "Slither 6/10/95 -- Changed test for no-object-size objects from being"; " (!o.object_size) && (!$recycler:valid(o)), which doesn't work."; "Slither 6/11/95 -- Added suspend_if_needed before creation starts"; "Slither 6/22/95 -- made it print error message if was making non-grabber GM owned object"; . @verb #4489:"trust_to_recycle trust_to_create" this none this @program #4489:trust_to_recycle ":trust_to_recycle(OBJ who [, OBJ what)"; "Is WHO allowed to recycle WHAT. If there is no WHAT, is WHO allowed"; "to recycle anthing that this.owner owns?"; return $local.rpg:is_grandmaster(args[1]) || (((length(args) > 1) && (args[1] in $local.rpg.gms)) && #10161:killable(args[2])); "DR 08-MAY-95 -- Trust GMs to manually recycle what the vacuum cleaner would consider food anyway."; . @verb #4489:"_recycle_old" this none this @program #4489:_recycle_old ":_recycle(object) - Pass to $recycler if perms are secure."; if (!this:trust_to_recycle(caller_perms())) return E_PERM; endif o = args[1]; if (!this:ok_to_recycle(o)) return E_NACC; endif recycled = $recycler:_recycle(o); if (o in this.owner.owned_objects) this.rotten = {@this.rotten, {o, callers()}}; endif return recycled; . "***finished***