Updated to use traits

Signed-off-by: Ninjaparade <ninja@ninjaparade.ca>