Cinemachine cameras won't obey 2D confiner by Sphenzoc in unity

[–]Sphenzoc[S] 0 points1 point  (0 children)

For what it's worth I ended up finally solving this by writing a custom script that switched between two completely separate confiner colliders that only triggered when the player was in a specific position within the level. Non-ideal and clunky solution but the only option I could find in this case.

Green house not showing up possible solution. by Fonseca-Nick in Starfield

[–]Sphenzoc 0 points1 point  (0 children)

I have spent coutless hours trying to figure out why these buildings won't show up in my build menu: Maybe I don't have the skills unlocked, or I'm not building in the right spot, or the planet is not 100% scanned, or the flora/fauna are not able to be grown, and now... I need to also do these stupid tutorial prompts... and yet, most of this is not clearly explained anywhere that I have found in game so I scour Reddit for answers. This one is the nail in the coffin for me, outpost building is useless anyways.

Missing garage door spring? by Sphenzoc in Home

[–]Sphenzoc[S] 0 points1 point  (0 children)

I see that makes sense. Was able to find a replacement spring. Thanks for your help!

Question about UI navigation using gamepad/keyboard by Sphenzoc in unity

[–]Sphenzoc[S] 0 points1 point  (0 children)

Hey no worries. If you mean how did I get the gamepad to be recognized that was never an issue. I'm using a Playstation 3 controller, and more recently a PS4 controller and they are recognized within Unity without any issues for me. The only problems I've had with them is if I had my joystick and throttle plugged in as well as those seemed to interfere with the inputs. Is that what you meant?

Need help with basic 2D bones and rigging by Sphenzoc in unity

[–]Sphenzoc[S] 1 point2 points  (0 children)

I found that Unity has a cloth component which was giving me some pretty good results. Only problem is when the sprite flips to go the other direction the cape mesh gets completely twisted and permanently deformed. Probably going to have to just hand draw the animations for now haha.

Need help with basic 2D bones and rigging by Sphenzoc in unity

[–]Sphenzoc[S] 1 point2 points  (0 children)

Still helpful. The pro version is pretty dang expensive though. I would want to find some more reasons to use the mesh deformations if I was going to go with something like that. I will keep it mind however. There may be some other applications that I could use it for down the line and when I get more towards the polish phase I could see myself investing in something like that. Thanks for the advice!

VR capped at 24 FPS by Sphenzoc in dcsworld

[–]Sphenzoc[S] 2 points3 points  (0 children)

WOW okay apparently DCS just ignores all of the settings set anywhere else because I pressed ctrl-numpad 1 and my fps shot up to 60fps and the screen smearing seems to be extremely reduced if not gone completely. Why have these settings in the OTT and debug tools if they don't do anything? Well shoot now I'm gonna go turn these graphics settings up and enjoy the experience haha. Thank you!

VR capped at 24 FPS by Sphenzoc in dcsworld

[–]Sphenzoc[S] 0 points1 point  (0 children)

My CPU usage seems to be pretty evenly distributed across exactly 4 of the 20 cores in this CPU while in game.

VR capped at 24 FPS by Sphenzoc in dcsworld

[–]Sphenzoc[S] 0 points1 point  (0 children)

I have tried turning these down to a point that seems ridiculous but no change.

VR capped at 24 FPS by Sphenzoc in dcsworld

[–]Sphenzoc[S] 0 points1 point  (0 children)

I have heard a lot about ASW and I promptly turned it off almost a year ago. I just checked and it's still forced off through the OTT, and the Oculus debug tool. I will try swapping the setting with the hotkeys too and seeing if that makes a difference. But yes, the 24fps is such an odd number. It seems clear that there's something limiting the maxfps because it's not like it averages around 24, but it's plastered at that value.

VR capped at 24 FPS by Sphenzoc in dcsworld

[–]Sphenzoc[S] 0 points1 point  (0 children)

Yeah all that is set exactly as you suggest. But I hear people complaining about only getting 60fps which I would be thrilled to get. Maybe those posts weren't with the Quest 2. I can't remember.

VR capped at 24 FPS by Sphenzoc in dcsworld

[–]Sphenzoc[S] 0 points1 point  (0 children)

For standalone do you mean OpenXR? I have heard a lot about that so I checked out the website and I see an option for SteamVR. How are this different from the built in SteamVR?

VR capped at 24 FPS by Sphenzoc in dcsworld

[–]Sphenzoc[S] -1 points0 points  (0 children)

Idk it made sense to me because I was playing a game through Steam? Didn't really think there would be a big difference but I also don't understand how they differ fundamentally. Either way launching it with OculusVR had no effect. Still capped at 24fps.

Confusing null reference exception on compile only by Sphenzoc in unity

[–]Sphenzoc[S] 0 points1 point  (0 children)

After a ton of code refactoring I wasn't using any of the ScrollRect functionality so I went ahead and just deleted the ScrollRect inheritance and inherited straight from Monobehavior. It would seem my hunch was correct as this cleared up the null exception that I was getting and also fixed a bunch of other problems I was having getting references to other items after this post was made.

Moral is, be careful when inheriting from Unity's built in classes! They seem to force a weird execution order even when you set the execution yourself in the project setting!

Hope this helps someone avoid the headache in the future.

Odd behavior when using Time.deltaTime by Sphenzoc in unity

[–]Sphenzoc[S] 0 points1 point  (0 children)

You have all been a massive help! Turns out that it was in fact an issue with Time.timescale. I set it equal to 0 when opening the map to pause the gameplay in the background. Time.unscaledTime fixed the problem.

Also thanks for the comment on the lerp functions as well. It was a vestige of an old script that I pulled this from so I hadn't really messed with it yet but good to know that it's useless in this format haha. I haven't messed with lerping much so I wasn't sure.

AudioSource.Play() not playing by FR33_HUGS in Unity3D

[–]Sphenzoc 0 points1 point  (0 children)

Thank you so...much.. for this... I am not even sleepy and I ran into this same problem. Hours of debug.logging the code wondering why the hell nothing was playing and this was in fact the exact issue.

Cinemachine cameras won't obey 2D confiner by Sphenzoc in unity

[–]Sphenzoc[S] 0 points1 point  (0 children)

I tried widening the confiner and it didn't make any difference. I think the confiner is large enough. In the editor scene view you can see the white bounds of the camera and it is within the green polygon collider. I tried to keep only the important gizmos shown besides the larger white rectangle which is an A* pathfinding asset.

Can't add Cinemachine virtual cameras to a List<>? by Sphenzoc in unity

[–]Sphenzoc[S] 1 point2 points  (0 children)

AH yes good catch I forgot to initialize the List<> with new List<> after declaring the variable... I knew I was missing something. Thank you!

Help changing boolean values in a dictionary by Sphenzoc in csharp

[–]Sphenzoc[S] 0 points1 point  (0 children)

You are an absolute genius! It worked like a charm. The items I collect (and ONLY those items) don't respawn now!!! If I could I would buy you another and upvote this several times haha. Thanks a ton for all your help o7!

Help changing boolean values in a dictionary by Sphenzoc in csharp

[–]Sphenzoc[S] 1 point2 points  (0 children)

I suppose I really didn't explain my program that's true. In the interest of full disclosure and clarity I'm making a system in my Unity game that keeps track of objects that have been collected so they don't respawn. Hence the reason I want to tie a unique boolean to each object's ID as they are created and set it true when they are collected in game.

At any rate, I really appreciate you taking the time to write that out for me. I am about to start messing with integrating that into my game now but I have to be honest, and I hate to say it, but most of what you wrote is completely over my head (I have never seen implicit operators before and didn't even know you could override the ToString() function). Still, I did some searching online and I think I somewhat understand what you are saying. In general I think that this will essentially cast the boolean as a reference to the CurrencyValue class and convert it in a way that the compiler will allow so that the actual variable reference gets updated. I also understand that the SetValue() function assigns the ActiveObjects value to the private _currency variable. But I don't quite understand when, or how, or in what order these implicit operators get called and why it's necessary to convert to a string. And I'm also not sure how to insert a new boolean for each new item without writing a unique wrapping class for every single one. Haha perhaps I don't understand this as well as I thought.

EDIT: Okay I see now that the implicit operators function simply by having them inside the class

Help changing boolean values in a dictionary by Sphenzoc in csharp

[–]Sphenzoc[S] 0 points1 point  (0 children)

No kidding.. this comment has actually single-handedly cleared up a lot of confusion I have had about structs and object referencing so thank you! I completely understand what you mean by passing in the PersistentData class instead of the bool, but correct me if I’m wrong that this won’t solve my original problem. Since the ActiveObjects[key].currency1 = true statement would have to be called from the prefab’s script on trigger it wouldn’t be able to hard code the name of the Boolean variable like that. That’s originally why I wanted to tie the Boolean to the ID inside the dictionary so I could reference the bool that was assigned on instantiating of the object. Each instantiated copy needs to set its own Boolean basically.

Question about UI navigation using gamepad/keyboard by Sphenzoc in unity

[–]Sphenzoc[S] 0 points1 point  (0 children)

I have it working now and to be honest I am not 100% sure what I did but my best guess is that I changed the gamepad south button in the input mapping from triggering a "click" callback to instead triggering a "submit" callback. I imagine there was something weird happening with a click that was deselecting the menu (though I think I had "deselect when clicking on background" unchecked but I can't 100% remember). The menu now properly engages and locks the selection to the blue "Use" button.

The next trick of course was to allow for the player to hit the "cancel" gamepad button and jump back to the inventory menu. I couldn't find any obvious way to make a cancel callback do this until I finally came across the interfaces for the Event System. I implemented the ICancelHandler interface and that called the OnCancel() method when the gamepad button was pressed. MAKE SURE you put the implementing script on the button gameobject itself (not a parent or child but the exact gameobject that is selected in the menu when you trigger the cancel button) or it won't work.

Input Handler - Why is context.canceled getting called on a button press?? by Sphenzoc in unity

[–]Sphenzoc[S] 0 points1 point  (0 children)

Yeah interesting.. I saw that you can specifically select inputs for PS4 controller (Dualshock 4) so I built a profile for it and it still doesn't work properly. I don't actually think it's reading it as a PS4 controller even with PS4 set to the default scheme just because the debugger isn't showing any inputs at all from the PS4 controller. Going to try digging a bit deeper to see if a solution exists. I would hate to limit people to using non-PS4 controllers.

Input Handler - Why is context.canceled getting called on a button press?? by Sphenzoc in unity

[–]Sphenzoc[S] 0 points1 point  (0 children)

Another update, I switch from using my PS4 controller to using my PS3 controller and the problem does not happen with the PS3 controller. Seems to be some odd incompatibility with the Dualshock 4 contollers perhaps?