You are reading and writing to Local Storage on every tick, this is very wrong.
You should write to local storage once at the end of the level/game, if CurrentScore>HighScore.
And read from Local Storage also just once - On Start of Layout, and only if HighScore=0. When HighScore already contains a value, you don't need to retrieve it from local storage.
I'm sorry for the late reply and thank you for trying to help me but I still don't understand. I try to change it a bit like in the picture bellow. But in the end of the game (player alive = 0) if the current score (TotalDistance) is greater than High Score, the high score number that showed in the end of game keep increasing for 3-5 seconds (there is no event for this increased number and for how many seconds. The higher the score is, the wait time for this number to settle is increased). But in the end it will set the new high score. For the score (TotalDistance) I still using scoring system at my first post (but I delete system > Add obj_player.Playform.Speed * dt to RECORD). I use this video for the high score tutorial wwwyoutubecom/watch?v=kfqNyZRaodg