1 | #!perl # mandatory |
1 | #!perl # mandatory |
2 | |
2 | |
3 | our $WAIT_TIME = 5 * 60; # 4 minutes |
3 | our $WAIT_TIME = 5 * 60; # 5 minutes |
4 | # the max price is base_price * 1.5 |
4 | # the max price is base_price * 1.5 |
5 | our $MAX_BASE_PRICE = 100 * 100 * 50; # 70 platinum (for lvl 115 players) |
5 | our $MAX_BASE_PRICE = 100 * 100 * 25; # 50 platinum (for lvl 115 players) |
6 | our $MIN_BASE_PRICE = 100 * 10; # 10 gold |
6 | our $MIN_BASE_PRICE = 100 * 10; # 10 gold |
7 | |
7 | |
8 | sub calc_player_price { |
8 | sub calc_player_price { |
9 | my ($name) = @_; |
9 | my ($name) = @_; |
10 | |
10 | |
… | |
… | |
50 | . " minutes.>"); |
50 | . " minutes.>"); |
51 | return; |
51 | return; |
52 | } |
52 | } |
53 | } |
53 | } |
54 | |
54 | |
55 | my (@stones) = cf::match::match <<'MATCH', $who; |
55 | my (@stones) = cf::match::match |
56 | (type=SIGN and { warn "MSG" . $_->msg; $_->msg =~ /hero.*killed.*by/si }) in inv |
56 | '(type=SIGN and { $_->msg =~ /hero.*killed.*by/si }) in inv', |
57 | MATCH |
57 | $who; |
58 | unless (@stones) { |
58 | unless (@stones) { |
59 | $who->reply ($npc, |
59 | $who->reply ($npc, |
60 | "I'm sorry sir, but you don't have any gravestones with you " |
60 | "I'm sorry sir, but you don't have any gravestones with you " |
61 | . "I'm interested in!"); |
61 | . "I'm interested in! " |
|
|
62 | . "H<He is only interested in gravestones caused by player deaths.>"); |
62 | return; |
63 | return; |
63 | } |
64 | } |
64 | |
65 | |
65 | cf::async { |
66 | cf::async { |
66 | my $ston = $stones[0]; |
67 | my $ston = $stones[0]; |