new money = cs_get_user_money(id)-get_cvar_num("armor_cost");
if(money < 1){// they can't afford it}else{// they can afford it
cs_set_user_money(id , money , 1); // the last param. makes it flash if set to 1}
__________________
What am I doing these days? Well, I run my own Rust server. It's heavily modded. If you'd like to join, the ip is 167.114.101.67:28116
I also created a website called Rust Tools. It will calculate and tell you the raw amounts of resources needed to craft items.