One example of the use of Continuous Event Processing is Ship Self Defense System which designed to automate threat analysis and quick threat engagement generation in real time. However, dynamic battlefield makes frequent risk analysis modification inevitable. Therefore, a rule-based approach is well suited to overcome this problem. RETE algorithm is a popular rule-engine algorithm which designed to manage and evaluate scalar and comparison rules. In addition, real time continuous risk analysis makes time become a sensitive aspect. In other words, an excellent risk analysis system would require spatiotemporal aspect to work as expected. Hence, we propose RETE algorithm with an additional improvement to deal with spatiotemporal rules. In according to those requirements as a risk analysis system, we propose Node Indexing that has similar technique with Continuous Query Indexing to avoid unnecessary data evaluation and sliding window to avoid event re-evaluation, which can reduce the overall time consumption.