Jump to content

  • Log In with Google      Sign In   
  • Create Account

Landi20

Member Since 14 Feb 2012
Offline Last Active Oct 17 2014 11:27 AM

Topics I've Started

Convert Xna Game to Sharpdx

27 September 2014 - 02:45 PM

how convert  my xna game to sharpdx

i using this sample to convert the xna to sharpdx

this is the link to sample

http://xbox.create.msdn.com/en-US/education/catalog/sample/collision_3d_heightmap_normals


problem with sample TiledResources

25 September 2014 - 08:38 AM

i create my world using this sample

https://github.com/sharpdx/SharpDX-Samples/tree/master/Toolkit/WindowsDesktop/TiledResources

and i have this error

Error    1    The type or namespace name 'TiledResourceCoordinate' could not be found (are you missing a using directive or an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\TileKey.cs    13    25    Central
Error    2    The type or namespace name 'TiledResourceCoordinate' could not be found (are you missing a using directive or an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\TileMappingUpdateArguments.cs    13    30    Central
Error    3    The type or namespace name 'TileRangeFlags' could not be found (are you missing a using directive or an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\TileMappingUpdateArguments.cs    14    30    Central
Error    4    The type or namespace name 'TiledResourceCoordinate' could not be found (are you missing a using directive or an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\TileKey.cs    16    24    Central
Error    5    The type or namespace name 'SubResourceTiling' does not exist in the namespace 'SharpDX.Direct3D11' (are you missing an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\TileLoader.cs    18    45    Central
Error    6    The type or namespace name 'PackedMipDescription' could not be found (are you missing a using directive or an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\ManagedTiledResource.cs    29    16    Central
Error    7    The type or namespace name 'TileShape' could not be found (are you missing a using directive or an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\ManagedTiledResource.cs    34    16    Central
Error    8    The type or namespace name 'TiledResourceCoordinate' could not be found (are you missing a using directive or an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\TrackedTile.cs    37    71    Central
Error    9    The type or namespace name 'SubResourceTiling' could not be found (are you missing a using directive or an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\ManagedTiledResource.cs    39    16    Central
Error    10    The type or namespace name 'SubResourceTiling' does not exist in the namespace 'SharpDX.Direct3D11' (are you missing an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\TileLoader.cs    39    63    Central
Error    11    The type or namespace name 'TiledResourceCoordinate' does not exist in the namespace 'SharpDX.Direct3D11' (are you missing an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\TileLoader.cs    73    62    Central
Error    12    The type or namespace name 'TiledResourceCoordinate' does not exist in the namespace 'SharpDX.Direct3D11' (are you missing an assembly reference?)    C:\Users\Pedro\Dropbox\GAMES\NeoforceControls-SharpDX-master\Central\Terrenos\TileLoader.cs    87    52    Central
 


how remove a model

14 August 2014 - 01:08 PM

i create a model in 3d but when i make logout and go to login class i don´t want show the model as been create in world class


problem with keyboard input

11 August 2014 - 06:16 PM

i porting my game in xna 4.0 with neoforce to sharpdx with neoforce

the problem it is i can´t  put in my game the keyboard input working

 public World(Game game, Manager ola, string text)
            : base(game)
        {

            NeoManager = ola;
           // HandleInput();
         //  Keyboard = new KeyboardManager(game); if uncomment this line say this service is allredy registed
        
            texto = text;
            System.Console.Write(texto);
            //   graphicsDeviceManager.PreferredGraphicsProfile = new FeatureLevel[] { FeatureLevel.Level_9_1, };
            pointer = new PointerManager(game);

          //  keyboarManager = new KeyboardManager(game);
            // this game system has something to draw - enable drawing by default
            // this can be disabled to make objects drawn by this system disappear
            Visible = true;

            // this game system has logic that needs to be updated - enable update by default
            // this can be disabled to simulate a "pause" in logic update
            Enabled = true;
            
            // add the system itself to the systems list, so that it will get initialized and processed properly
            // this can be done after game initialization - the Game class supports adding and removing of game systems dynamically
            Game.GameSystems.Add(this);
            
        }
 private void HandleInput()
        {
            KeyboardState currentKeyboardState =new KeyboardState();
              //  Keyboard.GetState();
     
           

            // Check for exit.


            // Now move the sphere. First, we want to check to see if the sphere should
            // turn. turnAmount will be an accumulation of all the different possible
            // inputs.
            if (currentKeyboardState.IsKeyDown(Keys.A) ||
                currentKeyboardState.IsKeyDown(Keys.Left))
            {
               // turnAmount += 1;
            }
            if (currentKeyboardState.IsKeyDown(Keys.D) ||
                currentKeyboardState.IsKeyDown(Keys.Right))
            {
               // turnAmount -= 1;
            }

            // clamp the turn amount between -1 and 1, and then use the finished
            // value to turn the sphere.
          


            // Next, we want to move the sphere forward or back. to do this, 
            // we'll create a Vector3 and modify use the user's input to modify the Z
            // component, which corresponds to the forward direction.
        

            if (currentKeyboardState.IsKeyDown(Keys.W) ||
                currentKeyboardState.IsKeyDown(Keys.Up))
                
            {
               
            }

            if (currentKeyboardState.IsKeyDown(Keys.S) ||
                currentKeyboardState.IsKeyDown(Keys.Down))
            {
                
            }
            if (currentKeyboardState.IsKeyPressed(Keys.I))
            {
                inventory.Show();


            }
            if (currentKeyboardState.IsKeyDown(Keys.B))
            {
                Charactersstatus.Show();


            }
            /* if (currentKeyboardState.IsKeyDown(Keys.Escape))
             {
                 if(tbc.Focused==true){
                 tbc.Visible = false;
                 }
                 //else
                 //{
                  //   tbc.Show();
                 //}
                
               //  InitConsole(text).Show();
                 //windows();

             }
            */
            // next, we'll create a rotation matrix from the sphereFacingDirection, and
            // use it to transform the vector. If we didn't do this, pressing "up" would
            // always move the ball along +Z. By transforming it, we can move in the
            // direction the sphere is "facing."
          

            // Now we know how much the user wants to move. We'll construct a temporary
            // vector, newSpherePosition, which will represent where the user wants to
            // go. If that value is on the heightmap, we'll allow the move.
          

            // now we need to roll the ball "forward." to do this, we first calculate
            // how far it has moved.
          

            // once we've finished all computations, we can set spherePosition to the
            // new position that we calculated.
       
        }

the error i have is this An unhandled exception of type 'System.NullReferenceException' occurred in TomShane.Neoforce.Central.exe

Additional information: A referência de objecto não foi definida como uma instância de um objecto.


change screen problem

04 August 2014 - 10:51 AM

i try a gamesystem when i try change the gamestament the graphics of 3d model is very poor 

and i don´t know how fix the problem

        public World(Game game, Manager ola, string text)
            : base(game)
        {

            NeoManager = ola;

            texto = text;
            System.Console.Write(texto);
            //   graphicsDeviceManager.PreferredGraphicsProfile = new FeatureLevel[] { FeatureLevel.Level_9_1, };
            pointer = new PointerManager(game);


            // this game system has something to draw - enable drawing by default
            // this can be disabled to make objects drawn by this system disappear
            Visible = true;

            // this game system has logic that needs to be updated - enable update by default
            // this can be disabled to simulate a "pause" in logic update
            Enabled = true;

            // add the system itself to the systems list, so that it will get initialized and processed properly
            // this can be done after game initialization - the Game class supports adding and removing of game systems dynamically
            Game.GameSystems.Add(this);
        }
 public override void Draw(GameTime gameTime)
        {


            NeoManager.BeginDraw(gameTime);the problem is where
            GraphicsDevice.Clear(SharpDX.Color.CornflowerBlue);
            model.Draw(GraphicsDevice, world, view, projection);

            /////GraphicsDevice.DepthStencilState = DepthStencilState.Default;
            ////  device.Clear();
            //// // Render the text
            spriteBatch.Begin();

            spriteBatch.DrawString(arial16BMFont, "Press the pointer to switch models...\r\nCurrent Model: " + model.Name, new Vector2(16, 16), Color.White);
            ////GraphicsDevice.Clear(Color.AntiqueWhite);

            //// GraphicsDevice.SamplerStates.Default;
            spriteBatch.End();


            //    GraphicsDevice.ClearState();

            NeoManager.EndDraw();// problem is cause by this 

            base.Draw(gameTime);

        
        }
   public Gamer()
        {
            // Creates a graphics manager. This is mandatory.
           
            graphicsDeviceManager = new GraphicsDeviceManager(this);
            graphicsDeviceManager.PreferredBackBufferWidth = 1280;
            graphicsDeviceManager.PreferredBackBufferHeight = 800;
            NeoManager = new Manager(this);           
            IsMouseVisible = true;
         
          //  _Login.Visible = true;

           // graphicsDeviceManager.IsFullScreen = true;
           // graphicsDeviceManager.re
          
            Content.RootDirectory = "Content";
     
  world = new World (this,NeoManager,"sa");
            
          
         

        }

PARTNERS