On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

Help

A topic by Ash K created Aug 30, 2021 Views: 439 Replies: 12
Viewing posts 1 to 7
(+1)

Got questions? Ask them below!
Know answers? Help people out!

P.S. No such thing as a dumb question.

Does anyone know any website with like a library of scripts, as like examples for common game features?
Like ¨Here is an example script for movement¨ ,  ¨Script for procedural beep boops¨ and such.

Submitted

The closest to that are probably the godot recipes by KidsCanCode: https://kidscancode.org/godot_recipes/

It is not a library of ready-made scripts though. But it will guide you with specific concepts and how to implement them.

Second that. Dont be discouraged by the name, they have the best tutorials for doing basic things in town, as a bonus most of them do not assume heaps of prior knowledge without being condescending. Also would recommend GDQuest and just googling the thing you want, sometimes people on reddit/stackoverflow will happen to be doing something very similar to what you are with someone in the comments suggesting the exact code you needed.

Submitted(+1)

The official documentation has a section called tutorials that also show how to do specific things, from simple logic like how to use a physics body to more complex like networking.

I'm not sure if there is a collection of snippets but almost everything is "plug and play", you can take the character scene and script files from a demo project and use it on your own project without changes in most cases.

Because I have a hard time explaining it. "What's a node tree system?"

(+2)

In Godot everything you can see and interact with is nodes. Each node can have 1 script attached to it. The nodes are organized in a tree graph (similar to how you would organize files in folders on a computer, except everything is both a file and a folder). Nodes contained under other nodes are its children. Nodes can have many children. Nodes can only have 1 parent. When a node moves, rotates or scales - its children do too. When it is deleted - its children are gone with it. You can also change the colour of the node and its children using modulate. 

In a script it is usually quite reliable to look for a node that is your child and can be done with $node/path or by using an export (NodePath) var path_to_node; onready var node = get_node(path_to_node) (it wont be gone unless you are gone and is added into the world with you). It is less reliable to look for a node that is your sibling, dont do it using get nodes, use collisions/areas and signals where possible (it can be gone without an announcement). It is usually somewhat reliable to ask for your parent  as there is always a parent (even if you are asking this in the top node of a loaded scene - there is always the root node), do it with get_parent().

If you want to make something a part of something - it should be its child (sprites + collision on a player, fancy animations on them, etc)
If you want things to independently interact - they should be siblings/under different parents so that they dont affect each other directly and instead do it through your intended channels (collisions, signals, etc)

Speaking about collisions. You might notice that each has a number of layers and masks. Collisions of layer 1 touch and can be touched by collisions with mask 1, but not other collisions of layer 1. If you want things to touch each other as normal - use both layer and mask. If you want players to hit walls but not each other - only use layers. If you want things that detect presence of players to not be triggered by each other - give them all masks so that they only react to players with only layers.

Submitted

Can I know after this game jam ended, got planning that this kind of game jam will host again?

Submitted(+2)

Point of advice, keep everything organized, make folders in your game for levels, characters ect... And make everything it's own scene, the player character gets their own scene. Tileset? Scene. Bad Guy? Scene. Bullets? Yep you guessed it another scene. This is so you can plop down things quick if you're making a new level. Would say more but I don't know much more then the various tutorials out there.

Im trying to make Dungeoncrawler-esque movement, but im having trouble making it collide with walls, i'm a bit lost..

(+2)

Assuming this is in 2d: Create a kinematic body, add a collision shape node as a child of kinematic body. Set the shape to be what you want it to be. Move kinematic body in code using move_and_slide(speed). To create collisions with walls create a static body and add the wall collisions as its children. Make sure the player kinematic body and the wall static body are on the same layers and masks. Make sure both layer and mask are enabled on each(important). (Layer+Layer do not collide, Mask + Mask do not collide. Layer+Mask collide.)

hope this helps!

Submitted

This might seem a little bit dumb, but since there is no winner in the game, is there a voting after submissions finished? Or this is a different jam? Just to make a game? 

(+1)

i believe this is a non competitive jam. the main focus is on learning a new skill and making people who have wildly different levels of tool familiarity compete with each other would be coutnterproductive. if you joined and learned a new skill  - that counts as a victory.