X-Git-Url: https://jxself.org/git/?a=blobdiff_plain;ds=sidebyside;f=misc.c;h=c219cfb059ec4b1f38570e208f1c7e498fd7fe45;hb=725105b4a24d245765d0f1c2f57e4014c6c7534b;hp=a2626b4d3f02ae66ea69ed4dbf99c4c1939debe0;hpb=c35cf999660d640bcf839792fa280855cf45c31b;p=open-adventure.git diff --git a/misc.c b/misc.c index a2626b4..c219cfb 100644 --- a/misc.c +++ b/misc.c @@ -402,7 +402,7 @@ bool yes(const char* question, const char* yes_response, const char* no_response for (;;) { speak(question); - char* reply = get_input(); + char* reply = get_input(); if (reply == NULL) { // LCOV_EXCL_START // Should be unreachable. Reply should never be NULL @@ -689,3 +689,10 @@ void bug(enum bugtype num, const char *error_string) // LCOV_EXCL_STOP /* end */ + +void state_change(long obj, long state) +/* Object must have a change-message list for this to be useful; only some do */ +{ + game.prop[obj] = state; + pspeak(obj, change, state, true); +} \ No newline at end of file