G
Godot Version Replace this line with your Godot version Question Hi! I’m looking for a partner to program with in Godot 4. Level: intermediate I want to make: simple games Availability: some hours per week, Lisbon time Goal: Make a good game 2 posts - 2 participants Read full topic
G
Godot Version 4.4.1 Question After fixing the placement bug I previously had, I found another bug that only allows one tower (duck) type to shoot, as the footage below shows: Only one type of duck actually fires projectiles, the Bazooka duck. Can anyone help with any fixes? Here’s some important lines of code to keep track of. #duck creation func create_minigun(event): var minigun = minigun_scene.instantiate() $Towers.add_child(minigun) #swapped minigun.setup(event.global_position)…
G
Godot Version 4.7 Question I keep getting the error: E 0:00:01:060 execute: There was previously a parse error: Expected ‘=’. <C++ Error> Condition “error_set” is true. Returning: Variant() <C++ Source> core/math/expression.cpp:1495 @ execute() But it doesn’t tell me which line of my code is throwing the error. I thought it was something in a physics_process since it returns an error every frame, but even after commenting out all physics_process scripts, the error persists. How do I track this…
G
Godot Version Replace this line with your Godot version Question Anyone know why my button in 2d is not working? it just passes through and doesnt press and doesnt focus 5 posts - 2 participants Read full topic
G
Godot Version Godot 4.7 Question hello! i’m running into a problem that probably has to do with signals getting mixed up somewhere. i’m trying to have the name of an item go from point A (a shelf) to point B (a maintainer node to hold everything together) to point C (a list of items) whereupon it marks the item as “done”. everything seems fine with the shelf telling the maintainer the name, but something seems to go wrong with the maintainer giving the name to the list; when interacted with,…
G
Godot Version godot 4.4 Question dive kicking in my game causes some weird stuff its supposed to land me in the ground but it bounces me a bit losing speed, can anyone help please also thanks in advance > extends CharacterBody3D enum states {N,slide,divekick,shinespark,knockbacked} var currstates : states enum wpns {crossbow,ball,t,f,fi} var currwpns : wpns #crrent speeds var currhorspeed : Vector3 var currverspeed : Vector3 var uncontrolled : Vector3 var currslidespeed : Vector3 #walking…
G
Godot Version 4.7.2 Question I have a StateManager that I added to the globals as GlobalStateManager (since it can’t be the same name.) Then I have a resume button that is supposed to talk to that global state manager. #ResumeButton.gd extends Button func _ready() -> void: pressed.connect(GlobalStateManager.resume_game) #StateManager.gd # [...] func resume_game() -> void: #[...] # [...] However, when unsafe call warnings are enabled it’ll throw the error: W 0:00:00:400 GDScript::reload: The…
G
Godot Version 4.7.2.mono Question func next_level() -> void: call_group("nodes", "queue_free") for i in range(1,7): spawn_node() func spawn_node() -> void: node.scoring_finished.connect(_on_node_scoring_finished.bind(node.stats, node)) node.tree_exiting.connect(_on_node_scoring_finished.bind(node.stats, node)) func _on_node_scoring_finished(stats, node) -> void: # post-scoring code... if all_scored: await %NextLevelButton.pressed next_level() func _on_node_tree_exiting(stats, node) -> void: #…
G
How do u create save function for instantated() stuff Godot 4.7.2 stable, mobile How do u make a save function that can save an instance u make, like i have a window where i intend to make it able to edit blocks and meshes on the players side, so i instinate that, add child, the. How do u get a save function the save the changes done in the actual instance, and save the instance that was created, in like a file or something. Like how many art apps can just save something uve made yea and put as…
G
Godot Version 4.5 Question Hi everybody! I’ve been working on a movement engine for a game. The basic idea is that you use the two analog sticks on the controller to move a character’s two hands, and you use those hands to vault off the environment and move around. After some testing and help from forum users, I managed to get a version of this system partially working! I’ll include my project files so you can download them yourself and play around with them. As you can see, the character can…
G
Godot Version 4.7.2 Question I’ve been trying to create a simple script that generates a straight road that is split into sections, however I can’t figure out how to fix an issue I’m having. var straightRoad = preload("res://Scenes/road.tscn") func _ready() -> void: for road in range(100): var instance = straightRoad.instantiate() instance.position.y = position.y + road * 10 // ERROR HERE The debugger is telling me that the instance I made does not have a position value, however the…
G
Godot Version 4.7.2 Question HI im a relatively new GDscript programmer who’s currently working on some simple projects but i’ve run into an issue i can’t figure out. so i am currently make a game for all intensive purposes is a small scale puzzle platformer where you throw a physics based projectile to hit lever’s and switches to do puzzles but im having some trouble with a specific aspect where you have a hit marker that follows your mouse to show where the projectile is aimed. but i want it…
G
Godot Version Godot 4.7.2 Question Hi! I have a 2D pixel art scene with a PointLight coming through a window.It is a light with shadows enabled, animated with an AnimationPlayer (position track, very slow movement). The shadows cast by LightOccluder2D nodes jitter / vibrate while the light moves. Setup: - Godot 4.7.2 stable, renderer: [Forward+ / Compatibility] - Stretch mode: canvas_items - Light texture: 64 px, node scale about (18.9, 14.4), Texture Scale 1 - Shadow filter: None (also tried…
G
Godot Version Godot 4.7.2 Question hi there. im new to this forum, and i need to ask a question because i cant find anyone who has had this issue aside from one. basically, whenever i try to spawn an object in the scene using instantiate and add child, i get an error that states when running “E 0:00:05:567 node.gd:15 @ _on_timer_timeout(): Condition “sdata.is_null()” is true. Returning: nullptr <C++ Source> scene/resources/packed_scene.cpp:232 @ instantiate() node.gd:15 @ _on_timer_timeout()”…
G
Godot Version 4.7.2 stable Question Trying to update the text of a label and keep receiving this error how do i assign it to string rather than null 25 posts - 2 participants Read full topic
G
Godot Version 4.7.2 Question I am making a game where you have to stay on a track, and I want to detect when the player has exited the area that is considered the track so that I can make them lose, however I haven’t been able to find out how to implement this properly. How do I get the Node that exited the track? 11 posts - 3 participants Read full topic
G
Godot Version Godot 4.6.2. stable Question I’m trying to make an enemy that shoot projectiles that can be hit, the enemy is perfectly fine except when I move to higher ground the enemy shoots the ground under me I’m not really sure which script is at fault, but I assume it’s this one v extends Node3D class_name BowWeapon @export var EXPLOSION_IMPULSE: float = 25.0 @export var show_aim := true @export var aim_high := false @export var ammo_resource:PackedScene @onready var spawn_point: Node3D =…
G
Godot Version 4.5.1 Question I want the player and enemies in my 3d game to have procedural animation, but I also want this procedural animation to affect the entire character, think Rainworld or Human fall Flat. How should I go about this (is there a plugin I can use?) 3 posts - 3 participants Read full topic
G
Godot Version Godot version 4.7.2 Question Hi. I’m new to game development and I’m trying to make my first game with this tutorial: https://www.youtube.com/watch?v=Ag_b7VsKXrc&list=PL4cUxeGkcC9jTpR5D2z-xy7YRnWh9xnFM&index=9 and until now everything worked fine but I have a Problem with the Enemy movement. Everytime I try to launch the Game it crashes and the Debugger says “Invalid access to property or key ‘position’ on a base object of type ‘Nil’.” But I did everything exactly as it was shown…
G
Godot Version 4.4.1 Question Hi y’all, not to sound like a broken record (because I just asked this on Discord) but I’m having issues with the placement of these ducks in a tower defense game I’m making, the video shows that they are not being perfectly placed to the mouse click. Here is my code: if selected_01 == true && Data.coins >= 100: if event is InputEventMouseButton: create_bazooka(event) print("Duck placed in", event.position) print("Bazooka selected: ", selected_01) Data.coins -= 100…
G
Godot Version 4.7.2 stable Question I’m working on a toy train game where the tracks branch out along the walls and surfaces and where the player has different points of interest to visit. I’m working the movement in the following way: the train is a PathFollow3D that follows the tracks which are Path3D and I have a set of Markers3D that specify the Vector3 global coordinates of my points of interests. The issue I’m having is that I can’t figure out how to translate the Vector3 coordinates to a…
G
4.7.2 Question I have a function that instantiates a set of cards in a grid inside of the main script and assign them their values via a function inside the card script, like this extends Node2D var chosen_cards : Array = [] ##Creo una PackedScene delle carte per poterne istanziare @export var card_scene : PackedScene = preload("res://Scenes/card.tscn") var screen_size #Semi e valori delle carte enum suits {clubs, diamonds, hearts, spades} const values = ["A", "2", "3", "4", "5", "6", "7", "8",…
G
Godot Version 4.7 Question Hello pretty people, i’m trying to make a system in which abilities costs hearts. imagine using an ability and it costs 2 out of your 5 hearts. those 2 hearts used would go on cooldown and for that cd time you would have only 3 hearts meaning that taking 3 dmg would kill you. after the cd time has expired the hearts are active again and you are back to the full 5. ive managed to make one heart work making it a progress bar that shows the cooldown but im having issues…
G
Godot Version 4.7.2.stable Question I’m trying my hand at making a simple top down shooter of sorts and for some reason I can’t find, the projectile seems to be offset on the y axis, if I print the position at the start seems to be 0,0, so that’s not it, rather than just offsetting it as needed I need to learn why that happens (I’m into this to learn at the moment). On the player node, on _physics_process: if Input.is_action_pressed("ataque"): var nuevo_proyectil = proyectil.instantiate()…
G
Godot Version 4.8 Question Need advises on how to approach waves generations in 2D top down game Hi! I am making a 2D top down game about exploring a mysterious archipelago. The game will be shipped with an editor that will allow people to add islands and modify the map. This means that islands are generated on the fly with resources that dictates their characteristics (shape, sprite, scale, etc.). The sea will also be editable by users. So it is made with different parallax layers that bear…
G
Godot Version 4.7 Question I am creating a bunch of buttons via script, and connecting them to a function when pressed.What I cannot understand is how to change the pressed button’s properties within the function itself. I would usually use .text, but I do not know what shoul I put before the dot. 4 posts - 3 participants Read full topic
G
Godot Version 4.5.2 Question I’ve been trying t learn more about how to use basis for transformations. I however don’t seem to understand them in application, I do theoretically. I decided to try rotating a cube to get a better understanding, but rather than learning how to use basis I just ended up using quaternions especially since I find them pretty easy to understand. I was hoping someone could point out weather this approach is correct. My script: func rotate_cube(): #convert to rad var…
G
Godot Version 4.7.2 Question I am using _make_custom_tooltip in order to replace the standard tooltip with a RichTextLabel. That has worked fine, but the tooltip sometimes appeared partially outside the screen I was able to fix this, but only by doing something that feels clearly unintented: grabbing the tooltip popup by connecting the RichTextLabel.ready to a custom function, forcing a popup() on it, and then updating the RichTextLabel.size to match it’s minimum size Updating it’s size to…
G
Godot Version 4.72 Question I’ve been trying to make a simple duck hunt game as a first project in Godot, but I’m having trouble with making ducks respawn. When I try to respawn more than one, I get an error saying that: bird.gd:35 @ _process(): Can’t add child ‘@Button@2’ to ‘Game’, already has a parent ‘Game’. Does anyone know what’s causing this and how to fix it? Thanks! if (position.y >= 400): var instance = birdResource.instantiate() for i in range(randi_range(1, 3)):…