aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarkus Uhlin <markus@nifty-networks.net>2024-03-24 00:33:10 +0100
committerMarkus Uhlin <markus@nifty-networks.net>2024-03-24 00:33:10 +0100
commit8aed61dadfb0b8f5e6ea8d25705a63c90671803f (patch)
tree128312c12e27ec1b82dd3892647de38310a8b7ca
parent20db761c19c3dd8a32acecdf7e70ade9b09a32d4 (diff)
Reformatted com_pending()
-rw-r--r--FICS/matchproc.c53
1 files changed, 31 insertions, 22 deletions
diff --git a/FICS/matchproc.c b/FICS/matchproc.c
index 6e7a4c9..d52fbd5 100644
--- a/FICS/matchproc.c
+++ b/FICS/matchproc.c
@@ -1093,28 +1093,37 @@ PUBLIC int com_withdraw(int p, param_list param)
return COM_OK;
}
-PUBLIC int com_pending(int p, param_list param)
+PUBLIC int
+com_pending(int p, param_list param)
{
- int i;
+ int i;
- if (!parray[p].num_to) {
- pprintf(p, "There are no offers pending TO other players.\n");
- } else {
- pprintf(p, "Offers TO other players:\n");
- for (i = 0; i < parray[p].num_to; i++) {
- pprintf(p, " ");
- player_pend_print(p, &parray[p].p_to_list[i]);
- }
- }
- if (!parray[p].num_from) {
- pprintf(p, "\nThere are no offers pending FROM other players.\n");
- } else {
- pprintf(p, "\nOffers FROM other players:\n");
- for (i = 0; i < parray[p].num_from; i++) {
- pprintf(p, " %d: ", i + 1);
- player_pend_print(p, &parray[p].p_from_list[i]);
- }
- pprintf(p, "\nIf you wish to accept any of these offers type 'accept n'\nor just 'accept' if there is only one offer.\n");
- }
- return COM_OK;
+ if (!parray[p].num_to) {
+ pprintf(p, "There are no offers pending TO other players.\n");
+ } else {
+ pprintf(p, "Offers TO other players:\n");
+
+ for (i = 0; i < parray[p].num_to; i++) {
+ pprintf(p, " ");
+ player_pend_print(p, &parray[p].p_to_list[i]);
+ }
+ }
+
+ if (!parray[p].num_from) {
+ pprintf(p, "\nThere are no offers pending FROM other players."
+ "\n");
+ } else {
+ pprintf(p, "\nOffers FROM other players:\n");
+
+ for (i = 0; i < parray[p].num_from; i++) {
+ pprintf(p, " %d: ", i + 1);
+ player_pend_print(p, &parray[p].p_from_list[i]);
+ }
+
+ pprintf(p, "\nIf you wish to accept any of these offers type "
+ "'accept n'\nor just 'accept' if there is only one offer."
+ "\n");
+ }
+
+ return COM_OK;
}