CocosSharp lack of documentation.

hgokturkhgokturk TRMember ✭✭

Hi. As a long term Cocos2d-X developer, I recently have a huge attention on CocosSharp of Xamarin.Forms. Besides I get most of the concept without any problem, still lack of documentation especially for CocosSharp Xamarin.Forms (in my case) strongly felt.
For example: How to make a version 1.7.1 CocosSharp Xamarin.Forms Portable game full screen? Maybe the simplest thing, but a big shame for the documentation that developers can't manage to get it done.

Posts

  • This will recreate the gameview everytime there is a change, usually screenrotate

    ` protected override void OnSizeAllocated(double width, double height)
    {
    base.OnSizeAllocated(width, height); //must be called
    if (this.width != width || this.height != height)
    {
    this.width = width;
    this.height = height;
    CreateNewGameView();
    }

        }
    

    `

    `
    void CreateNewGameView()
    {
    _gameView = new CocosSharpView()
    {
    HorizontalOptions = LayoutOptions.FillAndExpand,
    VerticalOptions = LayoutOptions.FillAndExpand,
    // Set the method to call once the view has been initialised
    ViewCreated = LoadGame
    };

            Content = _gameView;
        }
    

    `

    In LoadGame():

    _gameView.DesignResolution = new Size(viewSize.Width, viewSize.Height);

  • JOAOSerraJOAOSerra PTMember ✭✭

    i'm wasting my time trying to figure out where the Exit() is lol

Sign In or Register to comment.