Update of /cvsroot/slashmud/slashmudx/plugins/Gate
In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv4961/plugins/Gate
Modified Files:
gate.c
Log Message:
In process revisions for gate.c
Index: gate.c
===================================================================
RCS file: /cvsroot/slashmud/slashmudx/plugins/Gate/gate.c,v
retrieving revision 1.36
retrieving revision 1.37
diff -C2 -d -r1.36 -r1.37
*** gate.c 25 Apr 2008 05:26:15 -0000 1.36
--- gate.c 3 May 2008 02:48:02 -0000 1.37
***************
*** 62,75 ****
kGateMinKarma,
kGateMaxKarma,
! kGateRace, /* Not used because it is supported in the server. */
kGateSkill,
kGateGuild,
kGatePlayer,
! kGateMonster, /* Not used because it is supported in the server. */
kGateGender,
kGateWeather,
kGateDayNight,
kGateClanMinLevel,
! kGateClass, /* Not used because it is supported in the server. */
kGateItem
} pi_gate_pass_t;
--- 62,75 ----
kGateMinKarma,
kGateMaxKarma,
! /* kGateRace, Not used because it is supported in the server. */
kGateSkill,
kGateGuild,
kGatePlayer,
! /* kGateMonster, Not used because it is supported in the server. */
kGateGender,
kGateWeather,
kGateDayNight,
kGateClanMinLevel,
! /* kGateClass, Not used because it is supported in the server. */
kGateItem
} pi_gate_pass_t;
***************
*** 269,272 ****
--- 269,273 ----
{
smapi_note_ptr((Ptr) instance_data);
+ smapi_note_ptr((Ptr) instance_data->mPassList);
if (instance_data->mPassList != NULL)
***************
*** 718,722 ****
char buffer[kLineBufferBytes];
! self = (BasePtr) smapi_extract_parameter(event_ref, kParameterSelf);
if (self == NULL)
{
--- 719,723 ----
char buffer[kLineBufferBytes];
! self = (BasePtr) smapi_extract_parameter(event_ref, kParameterObject);
if (self == NULL)
{
***************
*** 779,788 ****
PassListPtr pass_list = NULL;
const char* string_ptr = NULL;
pass_list = smapi_malloc(sizeof(PassList));
if (pass_list)
{
- memset(pass_list, 0, sizeof(*pass_list));
-
pass_list->pass_type = pType;
pass_list->pass_value = pValue;
--- 780,788 ----
PassListPtr pass_list = NULL;
const char* string_ptr = NULL;
+ unsigned int result = 1;
pass_list = smapi_malloc(sizeof(PassList));
if (pass_list)
{
pass_list->pass_type = pType;
pass_list->pass_value = pValue;
***************
*** 791,796 ****
{
string_ptr = smapi_get_string(pName);
- assert(string_ptr);
-
if (string_ptr)
{
--- 791,794 ----
***************
*** 798,802 ****
}
}
! kg_list_add_last(instance_data->mPassList, (Ptr) pass_list);
}
}
--- 796,804 ----
}
}
! result = kg_list_add_last(instance_data->mPassList, (Ptr) pass_list);
! if (!result)
! {
! /* TOOD */
! }
}
}
***************
*** 853,857 ****
}
! remainder = strtok_r(NULL, "\"", &context);
if (remainder)
{
--- 855,859 ----
}
! remainder = strtok_r(NULL, " \"", &context);
if (remainder)
{
***************
*** 1029,1032 ****
--- 1031,1035 ----
}
}
+
else if (strcmp(token, "gate-item") == 0)
{
***************
*** 1305,1308 ****
--- 1308,1312 ----
snprintf(buffer, kSaveBufferBytes, "gate-gender %s", pass_list->pass_name);
}
+
else if (pass_list->pass_type == kGateWeather)
{
***************
*** 1319,1323 ****
snprintf(buffer, kSaveBufferBytes, "gate-item %s", pass_list->pass_name);
}
!
}
}
--- 1323,1329 ----
snprintf(buffer, kSaveBufferBytes, "gate-item %s", pass_list->pass_name);
}
!
! temp_line = smapi_get_string(buffer);
! kg_list_add_last(save_list, (Ptr) temp_line);
}
}
|