Questions tagged [godot-4]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
16 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
43 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
  • 13
1 vote
1 answer
60 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
0 votes
0 answers
39 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
  • 101
1 vote
0 answers
23 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
74 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
43 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
55 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
39 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
116 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
  • 131
0 votes
0 answers
29 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
107 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
96 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
55 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
51 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
135 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
74 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
92 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
362 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
268 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
48 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
59 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
251 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
  • 1
0 votes
0 answers
35 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
241 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
67 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
390 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
2 votes
2 answers
532 views

Drag and Drop Godot 4: Disappears when dropped outside allowed area

I'm trying to make a simple drag and drop function, and it works when dragging from one area to another, but if I accidentally drop the sprite outside the allowed areas, it just disappears. I've been ...
lzzard's user avatar
  • 23
1 vote
0 answers
101 views

How to share files between projects?

Ok so, I want to have a discreet client and server project. This project necessarily must have some of the same files so the server can do calculations/collisions/etc. Instead of having to copy files ...
Escoce's user avatar
  • 141
1 vote
1 answer
115 views

Why can't I get the AnimationTree node?

This is my code: ...
shadowxstrike's user avatar
2 votes
1 answer
456 views

Hide Children of Node

I am making a addon for my friends, and I am trying to make a custom node. It works, but I have a problem, the children of the custom node is visible in the scene dock. The ...
TheJalfireKnight's user avatar
-1 votes
1 answer
157 views

how can i make my jump animation and fall animation to work in godot 4.2? when i press jump it doesnt play the animation and when it fall, the same

this is the code im using ...
shadowxstrike's user avatar
2 votes
1 answer
207 views

Setting A Panel texture in GDScript

I am messing around with Godot, and I couldn't seem to find a way to set the texture of a Panel node in Godot. First I tried using the ...
TheJalfireKnight's user avatar
0 votes
0 answers
73 views

Pixel platformer character collides with blocks above while there's still a visible gap

I was trying to the set up a tile map for a 2D pixel art game in Godot 4.1 (following a tutorial) and realized that there seems to be an issue or something I am not aware of with the way collisions ...
JAL's user avatar
  • 1
0 votes
0 answers
206 views

Using 3D Rotation track animations in the AnimationPlayer in Godot

Godot v4.1.2.stable My goal is to make DirectionalLight3D rotate 360° around the scene, and in a second animation change the angle of rotation every 180 rotations between 75° and 30° on the X axis (a ...
vmBK8bS63vvAgitTrna25'i-h47gU''s user avatar
1 vote
2 answers
497 views

Simple Circuit System

I want to make a simple circuit system in Godot. Here's what I mean by that. (The circuit isn't realistic) I just want a battery object and a ...
TheJalfireKnight's user avatar
1 vote
1 answer
566 views

Actual Custom Nodes in Godot

So I am creating a plugin for Godot 4, and I want to create an actual custom node. What do I mean by that? First to create a custom node I do: ...
TheJalfireKnight's user avatar
0 votes
1 answer
255 views

Curves in Godot 4

I'm trying to figure out how to use curves to ease variable values in Godot 4. Ok, I've created a curve like this: @export var test_curve: Curve I set up my curve ...
ThetaJones's user avatar
2 votes
1 answer
94 views

How to make redirected player movement respond to same key?

I have a 2d game (Godot 4) with different rooms with portals to go between them, and some portals redirect the direction of the player while still holding the same key. I have that working so far, but ...
value1's user avatar
  • 23
0 votes
1 answer
131 views

"Springy legs" for a First Person Controller in Godot 4

I'm a total beginner, so I barely know what I'm doing, but here goes: I'm using this First Person Starter template and I would like to add a "springy legs" feature on character landing. The ...
ThetaJones's user avatar
5 votes
1 answer
440 views

How to get consistent collision impulse values for colliding rigid bodies in Godot?

I'm writing a game where you can pick and throw objects and depending on the force of the impact they break. Using the get_contact_impulse method to calculate the breaking point gives me very ...
Luke B.'s user avatar
  • 1,117
1 vote
1 answer
48 views

Prevent color adjustment in ViewportTexture

In Godot 4.1.1, I'm trying to use ViewportTextures to capture values generated by some shaders for use in another shader. One SubViewport is capturing the result of an unshaded spatial shader on a ...
stewbasic's user avatar
  • 170
0 votes
1 answer
129 views

When I inherit my own GDExtension class, editor can no longer see the inheriting class

I had two classes in my game, Player and ShootableObject. Both set up as such: ...
Tomáš Zato's user avatar
1 vote
1 answer
367 views

How to use the godot::String % operator for string formating of multiple values?

I tried this: godot::String str = "values: %f,%f"; double a = 1.0; double b = 2.0; str = str % a % b; Result string is: ...
Tomáš Zato's user avatar
3 votes
1 answer
133 views

How to make a CharacterBody2D slide out of StaticBody2D instead of teleporting?

I am trying to replicate Mario Maker's On/Off switches in Godot 4.1. In my current version, if the player got stuck inside the block after it was toggled on, the player just teleports out it. I know ...
Jason O'Neil's user avatar
2 votes
1 answer
270 views

Why does find_child not work during _ready, but looping over child nodes finds the child?

I have been trying to split a game object in half, starting with splitting the collision shape in half. I create two new clones of the split object, then give them a property to be assigned to the ...
Tomáš Zato's user avatar
0 votes
1 answer
97 views

change_scene_to_file successfully transitions scene, then transports back to the previous scene

I'm having a problem with change_scene_to_file in Godot 4. For some reason after the scene transition succeeded, I was automatically transported back the previous ...
Leon's user avatar
  • 1
2 votes
0 answers
318 views

How to make a callable type safe?

I can write a function like this: func foo(someCallableThatShouldReturnBool: Callable): if someCallableThatShouldReturnBool.call(): # do something ...
Kutub Gandhi's user avatar
0 votes
1 answer
688 views

How to check if a point is on the navmesh?

How do I know if a node is in within a navigation rectangle? I am working on an enemy spawner that puts enemies off screen but I need to pick positions where the enemies will actually work (read: on a ...
idbrii's user avatar
  • 798