Goblin XNA -- Creating a labyrinth style game - c#

Anyone know how to use Goblin XNA to implement ball control in the same way as one might find in the board game labyrinth?
There don't appear to be any tutorials or information at all regarding how to do this, despite there being a demo video displaying just such a thing.
I've setup the environment and gravity and added the ground and a sphere. I use WorldTransformation.Decompose to extract the current orientation of the board. I know the next step will be either ApplyLinearVelocity or AddForce to the sphere based on the current board orientation, but I don't know how to constantly apply these methods to the ball so that the ball is moving in response to the movement of the ball. Adding code to the Draw or Update methods only executes the code a single time. Anyone familiar with Goblin XNA at all and able to help?

As far as I can see in Goblin XNA the Update and Draw methods are called the same way as standard XNA games. Can you give more specific information? source code perhaps?

Related

Im trying to recreate spider square in unity but i cant figure out how to make the web

As stated in the title. I will include a video of what I'm trying to make. I'm not sure how to make the part that the player swings on.
https://youtu.be/Z_RVr0nFpVE
Description of the mechanic: when the player taps a "web" is created that goes from the player to the roof at a slight angle forward. This web gets shorter over time. When the player stops tapping the web goes away.
I’m sure that there is no physical rope or string simulation. The easiest way is to slow the horizontal speed down, add decelerating up-directed velocity, and draw a rope from the origin to the player. After parameters adjustment the result should look similar to what you’ve shown.

Spine Animaitons - Get the bone from an arm to follow the mouse

I am trying to get the arm in the spine animation to follow the mouse so it looks good when I shoot, here is an example of what I want it to do but using spine: https://www.youtube.com/watch?v=eofB2Z4-00w I have been looking through the code trying to find a specific method to develop a way to do this but have yet figured out a way!
Spine(http://esotericsoftware.com/) is an animation tool that I am using in unity for animations for a game that my team and I are developing. I am currently on the player controller and have been stuck on this part of the project for a week or so. I have developed a way to create a fire point using the bonefoller.cs script within spine-unity runtime, so it shoots from a specific position(Bone) that I set it to. Just need a way to let the arm from the shoulder to follow the exact position of the mouse so it works seamlessly. If there is anyone out there that has a background in using spine with unity that would be awesome to get some help from you! If there is also some documentation furthering my knowledge on how to do so that would also be accepted :) Thank-you in advance if you help me!!! :D
You need to construct a vector that has its origin at the shoulder position and its end at the mouse position, and the same for the arm (origin at the shoulder, end at the hand). Determine the angle between the two vectors and perform the necessary rotation on the arm to close the gap between the two vectors.

AI in different-shaped planets - Unity 3D

I am currently working in a Unity 3D project (in version 5.0.1 to be precise) in which the character can walk in different-shaped planets without falling. So it is always attracted by the planets gravity (similar mechanic to the Super Mario Galaxy games).
Now, the problem is when I try to code the AI for the enemies. This AI should be pretty much simple, but because of this thing that I have with the planets shapes, I haven't been able to come up with a solution. The enemy should check where the player is and move ahead to its position. It's a really dumb enemy. But the thing is, that the enemy must be able to track the player and get to its position no matter what planet he is in. So, if the planet is circular, I cannot make the enemy look at the player and then move forward, as I would do in a plane planet.
I have already tried using a NavMesh, but Unity doesn't want to collaborate and ends up making a NavMesh of 1/3 of the planet. I don't understand why. I have tried changing every single parameter of the NavMesh baking but I haven't succeeded.
Another problem that I would like to do is: ¿How would you make a player be able to walk on the surface of any planet, no matter what its shape, in a smooth way while using a Mesh Collider? I am currently achieving this by getting the planet's normal with a raycast, rotating the player so that the Y axis is perpendicular to the normal and applying a force in -Y to simulate gravity. But this brings lots of problems when I implement the Mesh Collider. It results in a jittery effect. But, when I use a primitive collider from Unity, it works fine...
Anyway. What I need the most now is the answer to the AI question. The other one is kinda like a plus.
P.S: It doesn't matter if the solution is in Javascript. I can then translate it to C# :)

Silverlight Collision Detection when controls are in different canvasses/layers

For our game we have to create collision detection.
The problem is that the collided objects are in different canvasses/layers, which makes collision detection by pointlocation inpossible.
Does anyone have an idea how to solve this?
It's hard to give a great answer without some more information, but if all your layers are the same size then you can just roll your own collision detection. All you need to know is the locations and sizes of two things to be collision detected. Then you just test to see if one rectangle intersects with the other rectangle.
There is also a function that might be useful to use called TranslatePoint. This translates from one UIElements coordinates to another. So if you had a ball bouncing around in a smaller area of the screen with it's own local coordinate system, you could get the ball's coordinates relative to the entire screen with this function.
Can I suggest you try using the Farseer physics engine just to save yourself some pain?
http://farseerphysics.codeplex.com/
It's very good and is in use in some WP7 games already.
http://www.farseergames.com/
There's also some Blend behaviors and helpers to make using it even easier:
http://physicshelper.codeplex.com/

Tile based collision in XNA

I have drawn tiles in my XNA game and loaded my character. My character, however, doesn't move- the map does, which gives it the illusion of movement. Now I am wondering how to actually test against them for collision. I mean, where does the collision code go and how do I make all tiles represent 'one big thing'?
There's a tutorial on pixel based collision detection on XNA Creator's club. You'll need to figure out what objects you want to do collision detection on. I guess you want the character to move across the tiled background, so you don't want to check for collision between your character and the background. Instead you should make any obstacle s sprites and do collision detection on those.
You might have a look at Nick Gravelyn's Tile Engine Tutorials, it goes through the whole process of creating a tile engine. There's a link here to see all the tutorials on YouTube.
You could have a look at the Platformer Starter Kit, it shows how to organize tiles in a map and check for collisions.
Rectangles have a intersects method. If your player is centered and you know the coordinates, loop through the other texture2ds and check for an intersection before scrolling the map.

Categories