Skip to main content

Questions tagged [godot-4]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
25 views

Walking through a portal attached to a wall

I have created portals that work perfectly fine. I walk into one and come out the other side seamlessly. The problem I am having, though, is when the portal is up against a wall my player (A ...
TheJalfireKnight's user avatar
0 votes
0 answers
43 views

How to hide a control node upon mouse click outside of it

I have a control node, let's call it Menu. It is a popup with some UI elements. It is shown when a button is pressed. It should be closed (hidden or maybe freed) when the player clicks anywhere ...
Jakub's user avatar
  • 45
0 votes
1 answer
25 views

Godot Blend Space 2D: Animations reset from start when blending discretely

Godot Version: 4.2.1 Mono How do I blend between animations in a Blend Space 2D while maintaining the playback point of animations? I don't want animations to restart each time I blend between them. I ...
Andrew Kay's user avatar
1 vote
0 answers
52 views

Game published for web freezes for 2-3 seconds the first time an explosion effect triggers

Using Godot 4.2.1 when exporting my game to HTML5 it runs completely fine until an explosion effect is spawned on screen for the first time when killing a mob, the game freezes for an entire 2-3 ...
buzzbuzz20xx's user avatar
-1 votes
1 answer
43 views

Finding grid squares a set number of hops away while avoiding obstacle cells, without AStarGrid

I am simplifying my project for clarity: I am currently making a game which has a 2D grid and a player moving on it. At the start of the players turn they roll a 6-sided die and can move that many ...
K M's user avatar
  • 1
0 votes
0 answers
57 views

My Godot 4 2D game is running badly on HTML5 on some PCs

using Godot 4.2.1, My game is a pretty simple top down shooter, I tried exporting to HTML5 on itch.io and the game runs fine on certain PCs but not others ?... when running the game on my computer ...
buzzbuzz20xx's user avatar
2 votes
2 answers
275 views

Area2D embedded in UI does not receive mouse events

I am using a hierarchy of Control nodes (in a CanvasLayer as was suggested in another question) to display a user interface. At ...
O. R. Mapper's user avatar
0 votes
0 answers
29 views

Inconsistent results from ApplyCentralImpulse with RigidBody2D

I'm working on a 2D top-down game using RigidBody2D for the player and enemies. They're bouncing and moving (using ApplyCentralForce) and detecting collisions just fine, however now I want to add a ...
Bryan Johnson's user avatar
0 votes
1 answer
190 views

adding a knockback effect to a CharacterBody2D in Godot 4.2.1?

i was following a tutorial series on YouTube on creating a Zelda clone in Godot 4.2.1 and everything works fine, but the tutorial never implements a knock-back effect when attacking an enemy so i ...
buzzbuzz20xx's user avatar
0 votes
1 answer
45 views

Movement continues for diagonal movement after releasing one key

For example, if I press W key and D key, that would produce a movement in the Northeast position. However, if I release either key (meaning I am holding only W or D at the moment), the movement still ...
JChips's user avatar
  • 1
1 vote
1 answer
108 views

Is it possible to set properties on a scene in a TileMap/TileSet?

If I have the following: sample of code showing exported properties: [Export] public TileSet TileSet { get; set; } [Export] public string TileName { get; set; } ...
Alexander Trauzzi's user avatar
1 vote
1 answer
101 views

Godot Array Reference Counting

Godot has several built-in types: Built-in types are stack-allocated. They are passed as values. This means a copy is created on each assignment or when passing them as arguments to functions. The ...
DavidT's user avatar
  • 271
0 votes
0 answers
95 views

Stray (orphaned) nodes remain after queue_free() of their parent scene

Godot 4.2.1 I have implemented a simple scene-save system: The Savegame Autoload listens for the S key press. When S is pressed, the ...
Noideas's user avatar
  • 17
0 votes
0 answers
89 views

gdExtension C++ failed to load gdexample.gdextension in Godot 4.1

I have followed the guidelines carefully on how to use gdExtension with c++ from the official site GDExtension with C++ Everything else seems okay but when I launched the Godot 4.1 editor, this error ...
javascript's user avatar
0 votes
1 answer
69 views

How to convert a dynamic VIewportTexture to a "static" one?

Assume there is a viewport that "looks" at some Sprite2D. This viewport's view is providing the texture for a Sprite3D ...
Noideas's user avatar
  • 17
1 vote
1 answer
170 views

Momentum for a First Person Controller in Godot 4

My First Person Controller (CharacterBody3D) currently has no momentum at all. By the way, I measure my movement speed in the debug panel (hotkey ~) with ...
ThetaJones's user avatar
0 votes
1 answer
43 views

How to get around mouse entry signal stopping at first collision?

I have a grid of Area3D objects, and when nothing is around them, they handle the mouse_entered signal exactly as I would expect. The only issue is that I also use Area3D's on other game objects, like ...
Fred Etingen's user avatar
0 votes
2 answers
110 views

FP Movement along the wall makes the character move faster and glitches out a little

First Person Movement along the wall makes the character move faster and glitches out a little. The problem is pretty much visible here: https://youtu.be/_1dDdCSwVEo Source: https://github.com/...
ThetaJones's user avatar
0 votes
1 answer
88 views

Assigning Color Won't Work

I am trying to make a palette-swap shader. Here is my code: ...
TheJalfireKnight's user avatar
0 votes
0 answers
42 views

Godot How to load encrypted pck file?

I can load .pck file with ProjectSettings.load_resource_pack(...) method. But when it comes to load encrypted .pck file, I can't load. So how can I load encrtpted ....
1 JustOnly 1's user avatar
0 votes
0 answers
37 views

Compute Shader - Buffer Output Size Differs From Input Image Dimensions

I am trying to build a compute shader to retrieve pixel color values from a noise-generated image using GLSL and Godot 4.2. The image itself is a 3840 x 2160 and formatted in RG8. I would expect ...
Haruto Kaito's user avatar
0 votes
0 answers
82 views

How to efficiently path many objects to a moving point?

Working in 3D in the Godot engine, I have an object that moves through space and, like a tornado, is intended to pick up objects in its path. What I have right now is janky, effectively re-baking the ...
Evan C's user avatar
  • 1
0 votes
0 answers
34 views

Texture space Raytracing of cylinder primitive in godot shader for Helix interception

I have been trying to do raytracing of an helix in a spatial shader in godot 4.2, but apparently I missed something because the result is bloby and melty at the cylinder level. The basics is that I ...
user29244's user avatar
  • 327
1 vote
1 answer
88 views

How to use Subviewports to render a texture for Sprite3D?

Godot 4.2 Background: In my game prototype, I have a following player entity: Paperdoll2D has a script that dynamically adds the weapon/armor/etc Sprite2D nodes to the main sprite to "dress-up&...
Noideas's user avatar
  • 17
1 vote
1 answer
153 views

Godot 4.2.1: Calling get_data() on Image from NoiseTexture2D Returns Null

I am trying to retrieve image data from a NoiseTexture2D. I seem to be able to get an image resource, but as soon as I try to get the associated data via ...
Haruto Kaito's user avatar
1 vote
0 answers
54 views

How to use resource that is already "in use" in scene

I started looking at a demo project in Godot (an included demo project for different particle effects), and there were GPUParticles2D nodes that spawned particles randomly along the white pixels of a ...
dekuShrub's user avatar
  • 111
1 vote
0 answers
67 views

How to use await with GDExtension-wrapped external library functions?

I am looking at wrapping functionality from an external C++ library with GDExtension for use with Godot 4. Many of these functions have an appreciable runtime before they return the values of interest,...
R.M.'s user avatar
  • 141
0 votes
0 answers
110 views

Terrain Determination in Perlin Noise Texture in Godot 4.2.1

For my Grand Strategy game, I am looking to use maps generated by Godot's FastNoiseLite implementation of Perlin noise. While generating the texture for the map was ...
Haruto Kaito's user avatar
2 votes
0 answers
197 views

How to connect two rigid bodies, then displace them relative to one another?

I want to temporarily connect multiple RigidBody2D objects in a Godot 2D scene so they move together as one rigid body, and later split them up again. I have ...
O. R. Mapper's user avatar
1 vote
1 answer
81 views

Sobotka's AgX in Godot 4?

Is it possible to use a custom OCIO called AgX in Godot 4? Has anyone ever tried something like this and succeeded?
ThetaJones's user avatar
1 vote
1 answer
227 views

In Godot, how do I reposition the center of my mesh?

When importing a Unity package to Godot via Unidot importer, I noticed that a few imported models have their child rotations and transformations off-center from their expected points. For example, ...
needoriginalname's user avatar
2 votes
2 answers
169 views

Turn a 2D array into a 3D map

I have a C# script that creates a random 2D array that is a map for a cave system. Sample Map: ...
AndyD273's user avatar
  • 163
0 votes
0 answers
34 views

How do you rotate a BoneAttachment3D during an animation?

I have a case where I want to rotate a bone that is otherwise controlled by an animation. The bone is the head bone of a humanoid skeleton. I have attached a ...
Escoce's user avatar
  • 141
0 votes
2 answers
195 views

Why are Quaternions better than Euler-Angles for Godot (when to use which)?

Sorry about the click-bait, I know there are many many reasons why Quaternions and Bases are better than using Euler-Angles. Anyone on a 5 second google search could easily know why! But I am trying ...
ZenPyro's user avatar
0 votes
1 answer
178 views

1px Font size too big for pixel art game - how to deal with this?

I have a pixel art kinda game that I'm building in Godot. I'm a newbie to both game dev and art. I have 32px high character sprites, with objects and the world scaled to be proportionate to those ...
WT_W's user avatar
  • 111
1 vote
1 answer
141 views

How to pause player motion during an air attack animation in Godot 4?

So I am very new to Game Dev, and I am running into a problem that seems like it should have a simple answer. Unfortunately, I have not been able to figure it out. I am creating a 2d side scroller. I ...
Bobb Starling's user avatar
3 votes
1 answer
71 views

Running a standalone Godot application on a Yocto 2.6 system with OpenGL3.0/ES2.0 hardware

I have an application that displays construction machines like excavators or snow groomers. The application is built on my company's custom engine, but I am trying to find out if I can port it to a ...
Kadir Erdem Demir's user avatar
1 vote
0 answers
177 views

Multiplayer Seamless Open-World Chunks

there is a made a game called JDungeon that looks like this: I want to add seamless chunk loading and unloading, meaning instead of the black world boundary, a new chunk loads in seamlessly. I'm ...
WithinAmnesia's user avatar
0 votes
1 answer
105 views

Sort an array of Node3Ds by distance with closest first

I am working on kart racing game. I have created a series of respawn points (Node3Ds) for when a player falls off of the track. Currently, I am trying to get the closest respawn point to the player ...
mjbelanic's user avatar
0 votes
1 answer
108 views

My CharacterBody3D Is getting blocked by ramps that act as walls

To summarize, my ramp is acting like a wall even if it is created to have a collision and mesh that fits its shape. I have tried: Putting the max angle to 90 using different ramps (CSG & mesh) ...
NEWBIE's user avatar
  • 23
1 vote
0 answers
746 views

Y-Sorting in 2D Isometric Games in Godot 4.x

I am having a problem with Y-sorting in an isometric Godot game. More specifically, when my character moves behind/in front of larger objects than one standard tile size, the rendering is inconsistent....
Gergely Kovacs's user avatar
3 votes
1 answer
677 views

Checking if a node is of a given type in Godot 4

I want to check if the player is near a door. In practice, this means that I want to check if the Area2D of the player node overlaps a door node (an ...
Eldy's user avatar
  • 835
1 vote
1 answer
75 views

Strange Marker2D behavior in Godot with barebones code

I'm new to programming in Godot but I've been playing around with things I've learned in various tutorials. That is, until I ran into the following issue which I can't seem to debug. I attached a ...
potatochopsticks's user avatar
1 vote
1 answer
127 views

What is the purpose of Uv_clipping in godot?

Can anyone tell me what is the purpose of uv_clipping property of rendering section in tilemap in godot with example? I don't understand what's the use of this property
saad virk's user avatar
0 votes
0 answers
763 views

How to scale UI for different screen resolutions

Godot 4.2.1, not a pixel art game. This is about scaling the UI, not sprites etc. I am targeting 1080p (base resolution), 1440p, and 4K. 4K is easy, I just set the scale to 2. But for 1440p, if I set ...
Jakub's user avatar
  • 45
0 votes
0 answers
43 views

Rotation inside MeshInstance3D surface plane

I'm trying to make a representation of a plane that rotates around a hole in a MeshInstance3D. So far I've managed to make the circle's hole, but I can't make the ...
Maya Rahto's user avatar
0 votes
1 answer
412 views

Detect collisions with both parent and child nodes in Godot

Using Godot 4.2.1, I have a 3D scene with a CharacterBody3D as the root. It has two children; a child CollisionShape3D, and a child CharacterBody3D with its own collision shape. ...
devil0150's user avatar
  • 123
0 votes
0 answers
88 views

How to rotate Scene Collection TileSet

I am using a scene in a TileMap node, but I can't seem to be able to rotate it. I tried rotating it in code, but that doesn't work. I also tried rotating it in the editor using the TileMap node. Is it ...
TheJalfireKnight's user avatar
3 votes
1 answer
775 views

Is there a way to instantiate a custom class decided at runtime in GDScript?

Can I instantiate a custom class during runtime through a String without knowing the value of the string when writing the code? Example: ...
Gidan's user avatar
  • 33
11 votes
3 answers
6k views

How can I structure my game like a "classical" program?

How can I setup a Godot 4 project in the way of a "classical" software project? With a Main function. Openable in any IDE. Compiling to an executable file ...
Zsar's user avatar
  • 235