Making objects non-mantleable
There is a spawnarg controlling whether objects can be mantled. It's called is_mantleable and it's 1 by default on most objects, meaning that those objects can be mantled in-game. Setting it to 0 on an object will cause any mantle attempts on that object to fail.
Examples of objects which aren't mantleable by default are candles, AIs, and weapons carried by AIs.
(For those not familiar with the term, "mantle" is basically a fancy word for clambering onto things.)