Godot 2.1.4 stuck on a node in script

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By toyson

Hello, i am having a problem with godot 2.1.4, i usually call lots of node into the script but i noticed that after a while, it gets stock on a node, if i try using another node it keeps on giving me the same property of the previous node, but the problem affects only that scene.
:::::::::SCRIPT::::::::::

extends Node2D
##PLAYER##
const PLAYER_SCENE = preload("res://Scene/Player.tscn")
var player_scene_instance
onready var player_spawner = get_node("Player_nodes/Player_spawner")
onready var player_camera = get_node("Player_nodes/Player_camera")
##

##GROUND##
const GROUND_SCENE = preload("res://Scene/Ground.tscn")
var ground_scene_instance
onready var ground_spawner = get_node("Game/Ground/Ground_nodes/Ground_spawner")
onready var ground_container = get_node("Game/Ground/Ground_nodes/Ground_spawn_timer")
var ground_spawner_speed = 500
var ground_velocity = Vector2(ground_spawner_speed,0)
##

##COIN##
const COIN_SCENE = preload("res://Scene/Coin.tscn")
var coin_scene_instance
onready var coin_spawner = get_node("Game/Coins/Coin_spawner")
onready var coin_container = get_node("Game/Coins/Coin_container")
var coin_spawner_speed = 20
var coin_current = 0
var coin_total = 0
##

##SCORE##
var score_current = 0
var score_best = 0
func _ready():
	set_process(true)
	pass

func _process(delta):
	**ground_spawner.translate(ground_velocity * delta)** --(this is the error given{{Attempt to call function 'translate' in base 'null instance' on a null instance.}})
	coin_total += coin_current
	if score_current > score_best :
		score_best = score_current
	pass


func PLAYER():
	player_scene_instance = PLAYER_SCENE.instance()
	player_spawner.add_child(player_scene_instance)
	player_scene_instance.add_child(player_camera)


func _on_player_timer_timeout():
	PLAYER()
	pass 

func GROUND():
	ground_scene_instance = GROUND_SCENE.instance()
	ground_container.add_child(ground_scene_instance)
	ground_scene_instance.set_pos(ground_spawner.get_pos())

func _on_Ground_spawn_timer_timeout():
	GROUND()
	pass 

func COIN():
	

This is the picture of the nodes i used

:bust_in_silhouette: Reply From: happycamper

If you are getting null instance, then when you set groundspawner it was unable to find the node. start looking at this line here->

onready var ground_spawner = get_node( "Game/Ground/Ground_nodes/Ground_spawner")

check to make sure your spelling is correct, case sensitive. I assume you manualy put Groundspawner node in the tree from the editor rather than adding it using gd script.