Issues with the ValueChanged tag event

I'm having issues getting my Valuechanged tag event to work correctly.The code I currently have for my ValueChanged event for my Set Temp Reached tag is:

if initialChange:
return
if ((previousValue.value == 0) and currentValue.value == 1):
system.tag.write("[.]Time Set Temp Reached",system.date.now())
if ((previousValue.value) and not currentValue.value):
system.tag.write("[.]Time Set Temp Dropped",system.date.now())

However, my Time Set Temp Reached tag is not being written to while my Time Set Temp Dropped is being written to. I want my tag to write to Time Set Temp Reached when the real time temperature reaches a specified temperature and write to Time Set Temp Dropped when the temperature drops below that specified temperataure. This is the code I have for my Set Temp Reached tag:

if ( {[.]realtime_temp} >= {[.]Set_temp},
1,
if ( ({[.]realtime_temp}+2 >= {[.]Set_temp}) && ({[.]time left} < {[.]Set_time}) && {[.]time left} != 0,
1,
0))

I believe only the expression language supports relative tagpath shortcuts. In jython, you’ll have to spell out the tag paths.

I just tried spelling out the tag paths but I still get the same result.