This post should explain how event controls interact with procedural blocks.
Since you declared i1 as a bit, its value is already 0. Assigning it to 0 doesn’t change its value. Even if you assigned it to 1, there’s a race condition because the procedural block might not see the change.