In order to correct the multitude of emails around, here is a text file with most of the fixes for mismatched errors in win95. Hope it helps -Caniffe ----------------------------------------------------------------- Julian Buckley, 2nd Year Computer Systems Engineering Dept. Computer Science and Electrical Engineering, Univ. of Qld E-Mail: buckley@pc.elec.uq.edu.au ----------------------------------------------------------------- --8<-- > Sometimes when I am compiling I get warnings about having mismatched > sizes, then it tells me a conversion was supplied. I am using MSVC through > windows 95, and bpl13a. I was just wondering why and if this may be a > problem, so something I can overlook. Everything seems to work fine, I just > want to avoid a problem before it happens, if in fact this is a problem. > Its not really a problem. Well, most of these have to do with rooms. The problem is that in many places in the code, rooms are refered to as sh_int (short integers).While many functions such as House_can_enter() expect a sh_int, and mscv5.0 seems to think that the GET_ROOM_VNUM returns only ints (even when explicitly type cast as sh_int, even though the returned type is a sh_int to begin with. Here is the list of files/line numbers that you'll want to explictly define their return type (after the macro). (list follows) act.wizard.c(192): int location, original_loc; with room_rnum location, original_loc; act.wizard.c(2352): char_to_room(vict, i); to char_to_room(vict, (room_rnum) i); comm.c(405): sa.sin_port = htons(port); to sa.sin_port = htons( (ush_int) port); db.c(1604): char_to_room(mob, ZCMD.arg3); to char_to_room(mob, (room_rnum) ZCMD.arg3); db.c(1614): obj_to_room(obj, ZCMD.arg3); to obj_to_room(obj, (room_rnum)ZCMD.arg3); db.c(1628): if (!(obj_to = get_obj_num(ZCMD.arg3))) { to if (!(obj_to = get_obj_num((obj_rnum) ZCMD.arg3))) { house.c(442): if ((i = find_house(atoi(arg))) < 0) { to if ((i = find_house((room_rnum) atoi(arg))) < 0) { house.c(485): else if ((i = find_house(atoi(arg))) < 0) to else if ((i = find_house((room_rnum)atoi(arg))) < 0) shop.c(1185): if ((k = get_char_num(SHOP_KEEPER(shop_nr)))) { to if ((k = get_char_num((mob_rnum)SHOP_KEEPER(shop_nr)))) { spec_procs.c(614): int pet_room; to room_rnum pet_room; spells.c(119): int to_room; to room_rnum to_room; And thats about it. PjD *** BPL13a+ ONLY *** act.movement.c(117): if (!House_can_enter(ch, GET_ROOM_VNUM(EXIT(ch, dir)->to_room))) { with if (!House_can_enter(ch, (room_vnum) GET_ROOM_VNUM(EXIT(ch, dir)->to_room))) { act.other.c(118): House_crashsave(GET_ROOM_VNUM(IN_ROOM(ch))); with House_crashsave((room_vnum)GET_ROOM_VNUM(IN_ROOM(ch))); act.wizard.c(179): !House_can_enter(ch, GET_ROOM_VNUM(location))) { with !House_can_enter(ch, (room_vnum)GET_ROOM_VNUM(location))) { house.c(528): else if ((i = find_house(GET_ROOM_VNUM(IN_ROOM(ch)))) < 0) to else if ((i = find_house((room_rnum) GET_ROOM_VNUM(IN_ROOM(ch)))) < 0) +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/15/00 PST