I uploaded the place files to Roblox as Uncopylocked Games for ease of accessibility and play testing
Hope you don’t mind.
I uploaded the place files to Roblox as Uncopylocked Games for ease of accessibility and play testing
Hope you don’t mind.
I might as well post my version of the place on here as well:
I’m not sure if it will always be public, but it is here for now. Also keep in mind that I have not created mobile controls for this yet. For right now, only keyboard and mouse is supported.
I figured out how to get the camera movement specifically to tween instead of the entire angle
, if you were stuck on that. I just made an extra xOffset
value since the offset and part:fakePart relationship is basically coupled together.
This also bugged out the ControlScript
, so I also made an extra camXSum
variable under CameraScript
to fix it.
Here are the individual scripts if you want to replace it, I also updated gravity swords up there to show this:
CameraScript.rbxm (3.6 KB)
ControlScript.lua (1.9 KB)
I also just integrated the custom ControlScript
with Roblox’s default one. Literally added three lines and changed one line. Surprisingly easy.
ControlScript.rbxm (47.5 KB)
I also published the change to gravity swords up there.
This is apparently only partial so far…
Update: The CameraScript is huge, I got the Classic camera integrated, but the Follow camera is causing trouble…
All this is in a separate game, so it has not been updated yet.
Update to the update: I just integrated CameraScript’s Classic
camera and Follow
camera modules, which are the two camera types provided to the player on default:
CameraScript.rbxm (80.2 KB)
If you need support for additional camera types, you can reply to this post, and I will try my best to integrate those scripts as well. I just updated gravity swords up there to show it.
I will begin work for the modification of the entire up-to-date module, which already looks much cleaner!
Don’t give them my secret!
In all seriousness I am very excited about this especially with it being open source. Thank you and good work!
also I did miss how old this is, sorry if that is against etiquette
I have now integrated the entire PlayerModule
, published on gravity swords:
PlayerModule.rbxm (125.6 KB)
This includes modifications to CameraModule.RootCamera
, CameraModule.ClassicCamera
, and ControlModule.BaseCharacterController
. The ClickToMoveController
doesn’t work because it requires a unique pathfinder, something I don’t think I have high confidence in creating because of its lack of correlation with the geometry of contorted unions and meshes.
I probably added about 100 lines in total, and it took me longer than it should’ve because of implementation details. Now that this is done though, this can be used as a component instead of its own standalone product, allowing for usage with other controllers, such as EgoMoose’s platformer controller, given the proper implementation.
I will need to unreverse X inputs when I get home
Done!
A cool idea would be nice like, when ur upside down your camera would rotate or move back to a normal fixed position so it just looks like nothing happened hhh.
Could you elaborate on what you mean by this? Are you suggesting some kind of cinematic camera? I could probably implement it into the CameraType.Watch
Enum. The CameraType.Watch
Enum is actually easier to implement in…
ok so basically, when you’re upside down on a part your camera should instead rotate like it was when you were normally on a surface part or something. hh
So like, you want an option to return the camera’s orientation to what it would be if it wasn’t accounting for gravity?
yeah, something like that basically.
Yeah, we have. Off topic, is there any way to make this character controller work when using swords, for example, have it support lunging and velocity changes?
This will probably merit for a new method in the controller for accessing the physCharacter
, honestly. Then you could apply physical BodyMovers
and Constraint
objects directly instead of via proxy to the real character. It’s easy to make, I could probably reproduce the code in this post real quick:
function controller:getPhysCharacter()
return self.physCharacter
end
In an outside module, if you don’t want to use that method, the controller has physCharacter
as a property, so you could probably access it from main
in StarterCharacterScripts
as:
controller.physCharacter
Doesn’t look like the place linked is uncopylocked
Right you are! My mistake; I must have not hit save. It should be open now
This couldn’t have come at a better time because I’m working on modifying the CameraModule to use any direction as its up.
Before I slog through your modified CameraModule, is there any convenient way to use it in my own game without your custom controller? Ex. In my game, I have a custom bee controller in which bees can land on walls, and I want the wall to become the floor.
Actually, the CameraModule
is not modified all too much, EgoMoose tried to isolate as much controller-specific details as possible to the controller
module in ReplicatedStorage
.
Also, what do you mean by using it in your game without the custom controller? Do you mean just turning off the gravity part of the controller so you can just use the camera portion?
That’s exactly what I mean – turning off the gravity while still using the camera portion. I’ll look through the controller
tomorrow and give it a go.
Thought I’d share this as a few weeks back somebody mentioned to me it would be cool if players could more accurately climb non-vertical ladders.
So here’s a very simple demo of that in action:
My point in showing this is to show that this module may be more versatile than you may think so get creative!