I am new to 3ds max and I am trying to link a weapon to the hands of my character, I am using link constraint but whenever I try to link it to the hands, the weapon suddenly gets scaled way up, and the weapon is rotated for some reason.
Before linking
after, check the scale
after, check rotation
I would try to reset XForm - that is likely the problem.
Related
I'm trying to make some reach-grasp trajectories in timeline. They work fine with the virtual robot. On the real Pepper, sometimes they execute fine, then, next try, the right arm doesnt move in the complete trajectory. If I then use the inspector to move the right shoulder pitch, it gets stuck around 50°.
I wonder if there is some stiffness, or force, parameter: it is as if the robot does not have the strength to make the movement.
You may debug the hand movement with a simple command line Python script that we have made for us. See https://nlp.fi.muni.cz/trac/pepper/wiki/SetArmPosition with a link to souce code.
Pepper has barely the strength to lift its arms when stretched.
When it does so, these motors get hot, and the power fed to them is reduced, to the point where the motion cannot be performed.
Prefer more complex motion, that requires less instantaneous strength to perform, for instance by using a bit of the roll motion, and by stretching the arms only at the last moment.
While trying to implement gravity in my "Donkey Kong" game, i ran into a problem. The jump movement works perfectly fine when Mario is on a platform. But however when he's falling from one platform to another, the collision with the next platform doesn't get detected and so mario goes through the platform.
This is how my gravity logic works: The vertical velocity is checked every frame, if it's not equal to 0 then mario is moved (+ mario-y vVelocity). As long as there is no collision with a platform, the vVelocity is changed to (- vVelocity gravity). And when there is a collision with a platform, the vVelocity gets reset to 0. The problem with this is, the mario-y changes too much every frame, for example it can go from (100;100) to (100;90) when the vVelocity= -10, and if there is a platform in (100;95), the collision is not detected. How can i fix this? Thanks
There at least two options.
Introduce a maximum velocity smaller than the size of a platform. In this way the player can’t pass a platform without a collision.
Use two or more time steps when you update the variables. So far your time step had the same duration as a frame. If you split the frame into several steps the velocity per time step will be smaller - as a result the player won’t move through a platform without a collision.
You should create line between last and current position and check line/platform intersection for collisions.
Also this is not Racket specific but general discrete simulation problem.
I have just started to use gamemaker and have made my first very basic game, it's just a circle that moves with the arrow keys.
My problem is that when it moves it leaves behind an image of itself in every space that it occupies.
All I have is $motion_set(0, 5);$ as the action.
Any help is much appreciated!
I am not really familiar with Studio 2 but in 1.4 your code causes my sprite to move across the screen without leaving anything behind. Are you sure there is nothing else in your code. It seems to be re-creating a new sprite either at the old location or creating a new object at the old location.
You can also you x += (the ammount of pixels you want to move) This works for x and y.
Thanks, Jonathan Greene
I'm working on a project where I'm capturing people making free throw shots via a video camera. I need a way to detect, as fast as possible, the instant the ball is released from a player's hand. I tried researching a lot of detection/tracking algorithms, but everything I've found seemed more suited to tracking the ball itself. While I may eventually want to do that, right now all I need to know is the release timing.
I'm also open to other solutions that don't use the camera (I have a decent budget), but of course I'd like to use the camera if possible/fast enough. I'm also able to mess with the camera positioning/setup, and what I even want in the FOV.
Does anyone have any ideas? I'm pretty stuck right now, and haven't been able to find anything online that can help.
A solution is to use visual markers (motion trackers) on the throwing hands and on the ball. The precision is based on the FPS of the camera.
The assumption is that you know the ball dimension and the hand grip on the ball that may vary. By using visual markers/trackers you can know the position of the ball relative to the hand. When the distance between the initial grip of the ball and the hand is bigger than the distance between the center of the ball and it's extremity then is when you have your release. Schema of the method
A better solution is to use a graded meter bar (alternate between black and white bars like the ones used on the mythbusters show to track the speed of objects). At the moment there is a color gap between the hand and the ball you have your release. The downside of this approach is that you have to capture the image at a side angle or top-down angle and use panels to hold the grading.
Your problem is similar to the billiard ball collision detection. I hope you find this paper helpful.
Edit:
There is a powerful tool, that is not that expensive named Microsoft Kinect used for motion capture. The downside of this tool is that it's camera works with 30 fps and you cannot use it accurately on a very sunny scene. However I have found a scientific paper about using kinect to record athletes, including free-throws in basketball. Paper here
It's my first answer on so. Any feedback on how to improve my future answers is appreciated.
I have a simple 2D game and I have a strange problem whenever a level is loaded several of the objects that include platforms and enemies won't display on screen and neither do the 2D background but all the objects are there, I can see it in the hierarchy and they are functioning as they should like killing the player and such. They just don't show up on the screen. I was finally able to show them while pausing the player during gameplay and set the z position of the camera to -11 and above but every time the level reloads like after the death of player, the same problem happens.
I even tested it on the mobile device but the same problem occurs furthermore I can't even interact with any of the UI buttons on the level, even though I check that all the code for them is appropriate.
Please help.
EDIT:
Okay after reading, your replies, I thought may be this will help. O always get these errors every time I load up this project in unity but they disappear once the game is running.
As you can see the platforms and enemies does appear on the camera frustum but when I start the game they disappear.
Okay, I finally found the problem. After lot of head scratching and testing I found that the objects that weren't appearing on screen has their z-position set to -10 which is the same of that of camera's z-position.
The problem was I was using this code to set the position of objects in the Awake method:
transform.position = camera.main.ViewportToWorldPoint(new Vector3(x, y, 0));
What's actually happening is all the x, y, and z co-ordinates were setting related to the camera's position. So setting the z-position to 10 fixed it for me.
Thanks everyone for helping me.
It's probably because near clipping of your cam is to high; Set it to 0.1 and try it again.