--- deliantra/server/ext/shop_ring.ext 2008/07/14 10:26:43 1.1 +++ deliantra/server/ext/shop_ring.ext 2018/11/18 15:19:48 1.4 @@ -1,23 +1,24 @@ #!perl cf::object::attachment "ring_adornment_shop", - on_auto_apply => sub { + on_reset => sub { my ($ob) = @_; my $o = cf::object::new 'ring'; $o->flag (cf::FLAG_IDENTIFIED, 1); $o->flag (cf::FLAG_UNPAID, 1); - $o->set_animation (cf::rndm $o->num_animations); + $o->set_anim_frame (cf::rndm $o->anim_frames); $o->insert_ob_in_map_at ($ob->map, undef, cf::INS_ABOVE_FLOOR_ONLY, $ob->x, $ob->y); cf::override; 1 - }; + } +; cf::object::attachment "amulet_adornment_shop", - on_auto_apply => sub { + on_reset => sub { my ($ob) = @_; my $arch = ('amulet', 'amulet_gray', 'amulet_white')[cf::rndm 3]; @@ -29,4 +30,5 @@ cf::override; 1 - }; + } +;