| 251 |
|
C_BOOL, |
| 252 |
|
{.intBoolVal = true}, |
| 253 |
|
{.intBoolVal = true} }, |
| 254 |
+ |
{ "daodaninput", |
| 255 |
+ |
"New input system that reports input on every frame, supports Raw Input for mice.", |
| 256 |
+ |
C_BOOL, |
| 257 |
+ |
{.intBoolVal = true}, |
| 258 |
+ |
{.intBoolVal = true} }, |
| 259 |
|
{ "directinput", |
| 260 |
|
"Enforces the usage of DirectInput on every system. Should be off for Linux/Wine.", |
| 261 |
|
C_BOOL, |
| 262 |
|
{.intBoolVal = true}, |
| 263 |
|
{.intBoolVal = true} }, |
| 264 |
+ |
{ "mousesensitivity", |
| 265 |
+ |
"Multiplier for Oni's mouse sensitivity. 1.0 is Oni's default.", |
| 266 |
+ |
C_FLOAT, |
| 267 |
+ |
{.floatVal = 1.0f}, |
| 268 |
+ |
{.floatVal = 1.0f} }, |
| 269 |
|
{ "disablecmdline", |
| 270 |
|
"Disables Oni's existing command line parser as Daodan has its own.", |
| 271 |
|
C_BOOL, |
| 309 |
|
break; |
| 310 |
|
case C_CMD: |
| 311 |
|
break; |
| 312 |
+ |
case C_FLOAT: |
| 313 |
+ |
STARTUPMESSAGE("Option %s.%s = %f (def %f)", config[s].name, co->name, co->value.floatVal, co->defaultValue.floatVal); |
| 314 |
+ |
break; |
| 315 |
|
default: |
| 316 |
|
STARTUPMESSAGE("Option %s.%s = %d (def %d)", config[s].name, co->name, co->value.intBoolVal, co->defaultValue.intBoolVal); |
| 317 |
|
} |
| 373 |
|
switch (type) { |
| 374 |
|
case C_INT: |
| 375 |
|
return "Int"; |
| 376 |
+ |
case C_FLOAT: |
| 377 |
+ |
return "Float"; |
| 378 |
|
case C_BOOL: |
| 379 |
|
return "Bool"; |
| 380 |
|
case C_STRING: |
| 405 |
|
return (boolV ? "true" : "false"); |
| 406 |
|
case C_CMD: |
| 407 |
|
return 0; |
| 408 |
+ |
case C_FLOAT: |
| 409 |
+ |
val = malloc(50); |
| 410 |
+ |
sprintf(val, "%f", optVal->floatVal); |
| 411 |
+ |
return val; |
| 412 |
|
default: |
| 413 |
|
val = malloc(20); |
| 414 |
|
sprintf(val, "%d", boolV); |
| 429 |
|
return 0; |
| 430 |
|
case C_INT: |
| 431 |
|
return opt->defaultValue.intBoolVal != opt->value.intBoolVal; |
| 432 |
+ |
case C_FLOAT: |
| 433 |
+ |
return opt->defaultValue.floatVal != opt->value.floatVal; |
| 434 |
|
} |
| 435 |
|
return 0; |
| 436 |
|
} |
| 547 |
|
case C_INT: |
| 548 |
|
co->value.intBoolVal = strtol(value, NULL, 0); |
| 549 |
|
break; |
| 550 |
+ |
case C_FLOAT: |
| 551 |
+ |
co->value.floatVal = strtof(value, NULL); |
| 552 |
+ |
break; |
| 553 |
|
case C_BOOL: |
| 554 |
|
co->value.intBoolVal = !_stricmp(value, "true"); |
| 555 |
|
break; |