CON access to ud.runkey_mode through get/setuserdef

git-svn-id: https://svn.eduke32.com/eduke32@3071 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2012-10-14 18:18:30 +00:00
parent 521ee43173
commit bc9a29b121
3 changed files with 11 additions and 0 deletions

View file

@ -1109,6 +1109,7 @@ const memberlabel_t UserdefsLabels[]=
{ "show_level_text", USERDEFS_SHOW_LEVEL_TEXT, 0, 0 },
{ "weaponscale", USERDEFS_WEAPONSCALE, 0, 0 },
{ "textscale", USERDEFS_TEXTSCALE, 0, 0 },
{ "runkey_mode", USERDEFS_RUNKEY_MODE, 0, 0 },
{ "", -1, 0, 0 } // END OF LIST
};

View file

@ -419,6 +419,7 @@ enum UserdefsLabel_t
USERDEFS_SHOW_LEVEL_TEXT,
USERDEFS_WEAPONSCALE,
USERDEFS_TEXTSCALE,
USERDEFS_RUNKEY_MODE,
USERDEFS_END
};

View file

@ -906,6 +906,15 @@ static void __fastcall VM_AccessUserdef(int32_t iSet, int32_t lLabelID, int32_t
Gv_SetVarX(lVar2, ud.textscale);
return;
case USERDEFS_RUNKEY_MODE:
if (iSet)
{
ud.runkey_mode = lValue;
return;
}
Gv_SetVarX(lVar2, ud.runkey_mode);
return;
default:
return;
}