NEW T-SQL technique! (or new to me).  The @@IDENTITY function has historically been flaky and susceptible to outside interference.  You must use it immediately after you do an insert if you want it to have the correct value, but even then, it can be clobbered by triggers that may have run in the meantime.  The T-SQL SCOPE_IDENTITY function and the IDENT_CURRENT have

SCOPE_IDENTITY
Returns the last IDENTITY value inserted into an IDENTITY column in the same scope. A scope is a module — a stored procedure, trigger, function, or batch. Thus, two statements are in the same scope if they are in the same stored procedure, function, or batch.

IDENT_CURRENT
Returns the last identity value generated for a specified table in any session and any scope.

Special thanks to Rick Dilling for using this technique in a stored procedure I was reading.  I haven't been able to confirm that this was added with SQL 2000, but it probably was.