• ✨ ARCHIVE MODE ✨
    The forum has now been set to read-only mode, no new posts, resources, replies etc will not be possible.
    We recommend you join our Discord server to get real-time response: Discord Invite Link

Raised Ledges

Status
Not open for further replies.

MrTimoshi

Fisherman
I posted this in the original forum under the suggestions board. I thought it was more fitting for the dev board. If it belongs in suggestions, please move it.

Anyway. The idea that I am presenting is to raise the area behind ledges instead of having them be wedges.

 

DanielRTRD

Webmaster
Administrator
P3D Developer
Contributor
Elite Four
I posted this in the original forum under the suggestions board. I thought it was more fitting for the dev board. If it belongs in suggestions, please move it.

Anyway. The idea that I am presenting is to raise the area behind ledges instead of having them be wedges.

I agree. This will make it more realistic. :)
 

Saruish

Dragon Tamer
I have develop some code for that but inorder for it to work. the legdes will have to be incontroll of how the player lands and where it lands at. Cause the Code I did made for it to test it out . got the character stuck in mid air.
 

DanielRTRD

Webmaster
Administrator
P3D Developer
Contributor
Elite Four
I have develop some code for that but inorder for it to work. the legdes will have to be incontroll of how the player lands and where it lands at. Cause the Code I did made for it to test it out . got the character stuck in mid air.
If you are able to make it work you can share the code with Nilllzz and he might add it in the game! :)
 

Saruish

Dragon Tamer
I have develop some code for that but inorder for it to work. the legdes will have to be incontroll of how the player lands and where it lands at. Cause the Code I did made for it to test it out . got the character stuck in mid air.
If you are able to make it work you can share the code with Nilllzz and he might add it in the game! :)
I cant cause the ledges which are under steps in map dont control where the player lands and I'm not sure where to find where it control at.
 

MrTimoshi

Fisherman
Would you be able to make ledges an action block to force it into an animation that puts the character down a level?
 

Saruish

Dragon Tamer
Would you be able to make ledges an action block to force it into an animation that puts the character down a level?
That what we need. with that we should be able to raise them up and fix the landing so the character is landing on walkable ground and not midair getting stuck.

Here the codes I got so far you'll need for different area's.

(for flat grass sloping upwards)For grassy hills
Code:
Stairs:
{"Entity"{ENT[{"EntityID"{str[SlideBlock]}}{"Position"{sngArr[0,0,0]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[96,16,16,16]]}}{"TextureIndex"{intArr[0,0,0,0,0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[2]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}}
for sandy(paths) hills
Code:
Stairs:
{"Entity"{ENT[{"EntityID"{str[SlideBlock]}}{"Position"{sngArr[0,0,0]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[112,16,16,16]]}}{"TextureIndex"{intArr[0,0,0,0,0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[2]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[2]}}]}}
for wall blocks for under ledges
Code:
Hill:
{"EntityField"{ENT[{"Size"{intArr[3,1]}}{"EntityID"{str[WallBlock]}}{"Position"{sngArr[0,0,0]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[160,16,16,16]]}}{"TextureIndex"{intArr[0,0,0,0,0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[1]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}}
The ledges are under step's in map. it looks like this

Code:
Steps:
{"EntityField"{ENT[{"Size"{intArr[2,1]}}{"EntityID"{str[Step]}}{"Position"{sngArr[6,0,5]}}{"TexturePath"{str[Routes]}}{"Textures"{recArr[[112,16,16,16][144,16,16,16]]}}{"TextureIndex"{intArr[1,1,1,1,0,0]}}{"Collision"{bool[1]}}{"ModelID"{int[7]}}{"Action"{int[0]}}{"AdditionalValue"{str[]}}{"Rotation"{int[0]}}]}}
Now the idea is to have a landing position that you can set. That where I'm messing up at. It looks all great but when you go off of it. it will leave you standing in midair and if you dont have a way to walk back, you'll be stuck. There isnt a landing code for the steps in maps and I don't know where to find it. also making warp blocks that connect from steps to the spot needed. doesn't work and causes the game to crash. So yea.. if you can find the golden goose to this issue then that will be great. Also you will need to raise and lower objects and make new walkable land on the same level of the slopes and such. to rasie and lower the land you will have to change the position of each object and such {"Position"{sngArr[6,0,5]}} is really {"Position"{sngArr[x,y,z]}}. X=North to south, Z=East to west, and Y= up and down(the levels of what the items restes on) Everything that around the same area your changing needs to be on the same level so what you need to do is change that to rest on the same level. but there still a issue of having the player land on the lower level when he/she/it goes off of the ledge.

Also Ceilings will have to be raise quiet a bit so they dont collide with the height change . Also places with ceiling changes may have to be inflated on the outside quiet a bit to make the illusion compete
 

DracoHouston

Kolben Developer
Contributor
I have develop some code for that but inorder for it to work. the legdes will have to be incontroll of how the player lands and where it lands at. Cause the Code I did made for it to test it out . got the character stuck in mid air.
If you are able to make it work you can share the code with Nilllzz and he might add it in the game! :)
What he seems to have done is get a 3d ledge going (there's a wedge model that is used for the stairs you can change the texture of, Saruish made it into grass/dirt ramps) but because it isn't pathable the player can't jump down them. If you use scriptblocks to try and move the player forward they will just walk into the air beyond the ledge and become stuck. script moves don't check for collisions or walkable surfaces unfortunately.

Nilllzz could still use the edited maps if they look good enough, but he would have to code in support for flagging the edge of a high area as a ledge, my suggestion would be 'jump blocks' that are script blocks that send the player to the destination with a jump animation and such. could be also built into script blocks as new script commands.
Would you be able to make ledges an action block to force it into an animation that puts the character down a level?
No animation or command to move down yet :( Scripts can make players and NPCs walk, but it does no checks for collisions and walks in the direction they are currently looking. NPCs that move during sequences don't turn and move for this reason, it is very primitive atm. It's 0.16 though, with time these things will improve.
 

DracoHouston

Kolben Developer
Contributor
What I would like from the move command is to just be able to give it a world position and have a pathfinder take care of the details. The other thing that should be added is the ability to make it so you can tell a script to move a character etc but continue to execute the script without waiting for them to reach their destination. if it was a keyword you could use on any script command it would be sick. If it were possible to run script commands without waiting for them to finish to continue a 'wait' command that pauses the script for an arbitrary amount of time, so if you do a command like that you can still have a pause before the next command is done.

This way you could have text pop up and not have it pause the scripts, have more than 1 npc moving at the same time (a follow command to make an NPC or the player stick to another NPC or the player would be useful too. it could path until it reaches the target, then it simply goes where the target last was whenever the target moves a tile)

There's going to be a lot of scripting by the time this game is done, try and make the engine do the tedious stuff for you.
 
Status
Not open for further replies.
Top