Closed Cervator closed 6 years ago
Hi @Cervator I would like to work on this. could you give some instructions? please
Hi @marti1125 .
Climbing is handled in the KinematicCharacterMover.findClimbable
. Likely, that a block with the climable property (see Core/assets/blocks/Ladder.block
for an example) would work.
BlockItemSystem
handles the placement of blocks and notifies the inventory item if the event is not consumed (OnBlockItemPlaced
-event and BlockInventorySystem
).
BlockPlacingSystem
does the actual placement, but I guess you want to build around this system and do a custom placing based on the blocks in the world (instead of attaching a ladder on a ladder, the ladder should be placed below the ladder). This could work with a higher event priority and consume the event for ladders (this also needs a check for the consumed event in BlockPlacingSystem
). Later on, we could improve this custom ladder placing system and forbid any other blocks that are about to be attached on a ladder.
Consuming the event while placing a block would break the OnBlockItemPlaced
-sending in the BlockItemSystem
. One way this could be handled is a separate boolean/int/whatever in the event, to indicate that/how many blocks have been placed and check for this flag instad.
You can finde more info about adding blocks in the TutorialAssetSystem.
For reference this is effectively complete with the https://github.com/Terasology/Climbables module - we just need to add it to the lineup if @portokaliu believes it is ready to go.
Hi @oniatus I am working on this issue π
Hi @marti1125 cool to see that you're still around :-)
The base implementation is complete in the Climbables module. Maybe you'd want to check that out, see if it works, and work on any remaining bugs or other improvements?
@Cervator sure!! can you guide me please π
I do not how to get start?
You need to add the Climbables module :-)
Be sure you've made yourself familiar with the basics: in the engine wiki, like https://github.com/MovingBlocks/Terasology/wiki/Developing-Modules
In this case you would:
gradlew fetchModuleClimbables
gradlew idea
After a moment IntelliJ should prompt you for a restart, or you can just restart it yourself.
Afterward you should have "Climbables" in your module list, in bold. Run the game and create a world with the module activated and get one or both the same blocks from the in-game console
give PoleSupport
give Pole
give ScaffoldSupport
give Scaffold
You should now have those as blocks - place the support block first, then while holding the other block of the type you can right click the support block to auto-extend it.
@Cervator Done!! π @oniatus Done!! π https://github.com/MovingBlocks/Terasology/wiki/Developing-Modules
Which part of the project I have to modify? :grin:
@Cervator @oniatus hello =(
Hey there! Sorry about the delay. We're buried by notifications these days (I'm up to some 3,000ish unread GitHub emails...) so it is really easy to miss comments anywhere. Saw this in my stream by chance :-)
If you were able to get it to work fine, what did you modify or what would you like to modify? Since the two base objects seemingly work already.
Feel free to join us on IRC, that's a waaaay easier way to find somebody to talk to as there are usually people around. Even if they aren't the right people they might still help or have ideas :-)
I just dusted off the Climbables module and made some minor updates to make it compile with the latest engine. Works fine after that so I'm going to add it to the lineup and consider this complete, although I'm sure it can still be enhanced. Work can continue within its own repo https://github.com/Terasology/Climbables
Another fairly easy one here inspired by Hacktoberfest and a recent IRC mention - could go in a module but since ladders are in Core I think we should add this there as well, until a later full piecing out of Core.
The difference between a regular ladder and a rope ladder should be the ability to place a ladder segment below the actively targeted existing rope ladder block, if the spot below is open. Then the player should be able to climb down and continue the ladder, while being able to edge out to either side enough to place additional solid blocks adjacent to the supporting column the ladder is placed against.
This should help the player travel downwards in cases like floating islands, deep vertical caves, and similar situations.
I don't think rope ladders should be able to go up, unsupported, that's what building a column of solid blocks with regular ladder blocks up against should be for.
Probably it should be very limited what can be attached to rope ladders - they should really only be for traveling downward to be able to then start a more proper support platform via other means.
It may be that the logic needs to be in a special ladder system that either catches block placement attempts of the specific block then redirects the placement target to spot below or make the rope ladder block itself special to where
e
clicking one attempts to fetch another rope ladder from the player's inventory and placing it below the target block.Current ladders have no special placement logic and just movement against them is handled in
KinematicCharacterMover
(probably should remain unchanged and just also count for rope ladders)