rogerzor Posted November 22, 2016 Group: Members Topic Count: 2 Topics Per Day: 0.00 Content Count: 3 Reputation: 0 Joined: 05/25/15 Last Seen: November 22, 2016 Share Posted November 22, 2016 Some one can help me with this 16102:6: error? Thanxs clif.c:16102:3: error: too few arguments to function ‘clif_cashshop_ack’ clif_cashshop_ack(sd,npc_cashshop_buy(sd, nameid, amount, points)); clif.c:16026:6: note: expected ‘struct npc_data *’ but argument is of type ‘int’ void clif_cashshop_ack(struct map_session_data* sd, struct npc_data* nd, int error) ^ clif.c:16102:3: error: too few arguments to function ‘clif_cashshop_ack’ clif_cashshop_ack(sd,npc_cashshop_buy(sd, nameid, amount, points)); ^ clif.c:16026:6: note: declared here void clif_cashshop_ack(struct map_session_data* sd, struct npc_data* nd, int error) ^ make[1]: *** [obj_sql/clif.o] Error 1 make[1]: Leaving directory `/ Quote Link to comment Share on other sites More sharing options...
0 Rynbef Posted November 22, 2016 Group: Forum Moderator Topic Count: 48 Topics Per Day: 0.01 Content Count: 941 Reputation: 125 Joined: 05/23/12 Last Seen: Tuesday at 04:54 PM Share Posted November 22, 2016 Backup your clif.c and try to replace the function "void clif_cashshop_ack(struct map_session_data* sd, struct npc_data* nd, int error) " with: void clif_cashshop_ack(struct map_session_data* sd, int error) { int fd, cost[2] = { 0, 0 }; struct npc_data *nd; nullpo_retv(sd); fd = sd->fd; nd = map_id2nd(sd->npc_shopid); npc_shop_currency_type(sd, nd, cost, false); WFIFOHEAD(fd, packet_len(0x289)); WFIFOW(fd,0) = 0x289; WFIFOL(fd,2) = cost[0]; #if PACKETVER < 20070711 WFIFOW(fd,6) = TOW(error); #else WFIFOL(fd,6) = cost[1]; WFIFOW(fd,10) = TOW(error); #endif WFIFOSET(fd, packet_len(0x289)); } The function have now only 2 arguments. Rynbef~ Quote Link to comment Share on other sites More sharing options...
0 rogerzor Posted November 22, 2016 Group: Members Topic Count: 2 Topics Per Day: 0.00 Content Count: 3 Reputation: 0 Joined: 05/25/15 Last Seen: November 22, 2016 Author Share Posted November 22, 2016 (edited) 5 minutes ago, Rynbef said: Backup your clif.c and try to replace the function "void clif_cashshop_ack(struct map_session_data* sd, struct npc_data* nd, int error) " with: void clif_cashshop_ack(struct map_session_data* sd, int error) { int fd, cost[2] = { 0, 0 }; struct npc_data *nd; nullpo_retv(sd); fd = sd->fd; nd = map_id2nd(sd->npc_shopid); npc_shop_currency_type(sd, nd, cost, false); WFIFOHEAD(fd, packet_len(0x289)); WFIFOW(fd,0) = 0x289; WFIFOL(fd,2) = cost[0]; #if PACKETVER < 20070711 WFIFOW(fd,6) = TOW(error); #else WFIFOL(fd,6) = cost[1]; WFIFOW(fd,10) = TOW(error); #endif WFIFOSET(fd, packet_len(0x289)); } The function have now only 2 arguments. Rynbef~ clif.c: In function ‘packetdb_readdb’: clif.c:19192:5: error: ‘clif_parse_cashshop_buy’ undeclared (first use in this function) { clif_parse_cashshop_buy, "cashshopbuy" }, ^ clif.c:19192:5: note: each undeclared identifier is reported only once for each function it appears in Now he is reporting that. @edit: My bad, I forgot saving the file. But now is correct. Edited November 22, 2016 by rogerzor Quote Link to comment Share on other sites More sharing options...
0 Rynbef Posted November 22, 2016 Group: Forum Moderator Topic Count: 48 Topics Per Day: 0.01 Content Count: 941 Reputation: 125 Joined: 05/23/12 Last Seen: Tuesday at 04:54 PM Share Posted November 22, 2016 (edited) Please paste your clif.c at http://pastebin.com/ otherwise I cant resolve your problem. Edited November 22, 2016 by Rynbef Quote Link to comment Share on other sites More sharing options...
Question
rogerzor
Some one can help me with this 16102:6: error? Thanxs
clif.c:16102:3: error: too few arguments to function ‘clif_cashshop_ack’
clif_cashshop_ack(sd,npc_cashshop_buy(sd, nameid, amount, points));
clif.c:16026:6: note: expected ‘struct npc_data *’ but argument is of type ‘int’
void clif_cashshop_ack(struct map_session_data* sd, struct npc_data* nd, int error)
^
clif.c:16102:3: error: too few arguments to function ‘clif_cashshop_ack’
clif_cashshop_ack(sd,npc_cashshop_buy(sd, nameid, amount, points));
^
clif.c:16026:6: note: declared here
void clif_cashshop_ack(struct map_session_data* sd, struct npc_data* nd, int error)
^
make[1]: *** [obj_sql/clif.o] Error 1
make[1]: Leaving directory `/
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.