As I mentioned, the only way that you'll be able to duplicate your existing logic is to start a transaction and aquire the lock on the resource. SQL Server will hold the lock until the transaction terminates and this could have SERIOUS effects to the concurrency of your application.
Cetin made a good recommendation: include a starttime in your lock table and provide your locking procedure with a rule that allows locks to timeout.
-Mike