ID:2708644
 
Applies to:DM Language
Status: Open

Issue hasn't been assigned a status value.
if I set an 'input as num|null', I can't press ok without any values set, so I'd have to at least type a '0' or have a default value set, which isn't optimal.

What I'd want is if you don't type anything and press ok, it'd count as null/0 if the option is avaiable. This already happens with 'input as text' where if you press ok with the input being blank, it returns an empty string. Therefore, to be consistent, 'as num' should return a 0.

If you specify null as a valid option, then null should be allowed for ok.
It seems like you're saying two different things here.

On the one hand it sounds like you're suggesting that an input as num|null should always have a default value, and if none is specified it should be 0.

But on the other hand it sounds like you want null to be a valid return value when hitting OK. That makes no sense to me at all.
In response to Lummox JR
Well the correct thing for me would be it returning null when hitting ok if null is declared as an option, but current byond behaviour in inputting text returns an empty string, so to be consistent it should return a 0. The more correct for me would be overriding the behaviour on input text too tho. So it all depends on what you think is best.