That doesn't do the same thing.
ord("W") is 87
vk_space is 32
Therefore, ord("W") || vk_space = 87 || 32 = 1
Basically, you're checking a key that doesn't exist on keyboards. Code isn't English; you can't treat it as such. You'll have to do what FrostyCat says and separate the expressions:
Code:
keyboard_check_pressed(ord("W")) || keyboard_check_pressed(vk_space)