New answers tagged godot-4
3
votes
Accepted
Why is this Godot extension class still considered abstract?
I just ran into this while trying to extend StreamPeer to handle serial devices. It turns out that there is a StreamPeerExtension that is supposed to be as the base class instead. Using that got rid ...
1
vote
Accepted
Setting A Panel texture in GDScript
You can set an StyleBoxTexture to the Panel either by:
Defining it in a Theme which you set ...
0
votes
How to get consistent collision impulse values for colliding rigid bodies in Godot?
You could make each object compute its own impulse using linear momentum change. This solution uses Signals and tracks state variables manually. It works for linear momentum only, but you can extend ...
1
vote
Simple Circuit System
tl;dr: model the circuit network as a linear system of equations to easily solve for the current and voltage at every node using off-the-shelf linear algebra software.
It depends how realistic you ...
3
votes
Accepted
Simple Circuit System
One option is to group all the connected wires into a single logical network that handles distributing power. This has the advantage of being very cheap except when dealing with removing connections ...
1
vote
Accepted
Actual Custom Nodes in Godot
If you make an script like this:
@tool
extends CharacterBody2D
class_name Player2D
Then you can add a CharacterBody2D to your ...
2
votes
Accepted
How to make redirected player movement respond to same key?
Not tested, but you could try looking at which keys the player is pressing when they're warping and setting the velocity x/y values to 0 when they're released depending on how much the movement is ...
0
votes
change_scene_to_file successfully transitions scene, then transports back to the previous scene
You're checking for user input in _process(), which is executed every frame. It's possible that the interaction key is not released before reading user input during ...
0
votes
"Springy legs" for a First Person Controller in Godot 4
You could use a tween to bounce the camera when you land.
That requires two things:
detecting when you land
bouncing the camera
Modifying MovementController.gd in the template you're using to ...
1
vote
Accepted
Prevent color adjustment in ViewportTexture
If this is due color conversion (as DMGregory guesses), then I think your sampler2D need source_color. Example:
...
Top 50 recent answers are included
Related Tags
godot-4 × 103godot × 38
gdscript × 28
2d × 6
tilemap × 6
physics × 5
shaders × 5
gui × 5
c# × 4
c++ × 4
3d × 4
collision-detection × 3
animation × 3
movement × 3
platformer × 3
navmesh × 3
ui-design × 3
godot-3 × 3
procedural-generation × 2
path-finding × 2
vector × 2
html5 × 2
isometric × 2
fragment-shader × 2
screen × 2