implemented template @evilaliv3 @hellais