Page 1 of 3 123 LastLast
Results 1 to 10 of 22
  1. #1
    Join Date
    Feb 2014
    Posts
    201

    Doin' the MMO vids again

    I needed to rebuild my PC and because the MMO project uses a lot more than the BitBucket repository, I decided to start the project again and go really slow and try to get the most out of it - ie not just get the results on-screen but to understand the stuff in it.

    I also decided to add in the best bits of the "Comprehensive ASP.NET MVC course", so expect some diversions along the way as they are added in to the website.

    Notes:

    Video 3 - Setting up our Projects
    * Bitbucket and Sourcetree are now more tightly linked allowing a fairly painless setup of your version control starting with linked accounts. Nice if you want to use Bitbucket.
    * Since the vids, a few more versions of .net have become available. I decided to give 4.6.1 a try instead of 4.5.1 for the non unity projects. I remember trying that once before with some bad results. Let's see what happens this time especially in Photon differences between v3 and v4.
    * In mid-March 2017 Visual Studio 2017 became available. I'm using that now.
    * Unity3d now creates a folder of your project name under the location. Odd but no big deal once you 'get' it. (I wish the Unity3d front end had a delete button.)
    * Creating the web project in VS2017 was a little bit different. ASP.NET is a single option now. Once you hit ok you can tick the box to create an empty project as well as tick the MVC box. When installing VS, you do need the ASP.NET option so make sure it's ticked.
    * Visual Studio 2017 and Resharper now has TeamCity addins as well as .git pushes built in. I decided to ignore all that goodness until later and just let Visual Studio create it's own separate .git repository. TeamCity has probably changed somewhat. Microsoft do push their own hosting providers a lot now.
    * Resharper Options|General has a pull down to select where you store the cache. To get it the way Nelson has it, select "Solution Folder". Yep just so we can ignore the "_ReSharper.Caches" folder in the project it when we do a commit.
    Last edited by oldngrey; 03-12-2017 at 06:54 AM.

  2. #2
    Join Date
    Feb 2014
    Posts
    201
    Video 4 - 004 Setting up our Website

    This is where things get awkward.
    I first tried installing the latest versions of BundleTransformer.Less and JavaScriptEngineSwitcher.V8
    But both fail unless I use older versions: no later than 1.5.8 for the .V8 package and 1.9.92 for the .Less package.

    Now I have to ask myself the question: do I try to figure it out or do I try and stay at Nelson's code?
    For the time being, I have taken the easy way out and just kept the versions mentioned above.

    However I did use the NuGet package "Bootstrap Less" instead of manually copying them in. The NuGet package is now the same version as the downloadable version from the website. The only difference is that the Bootstrap folder is one level higher up. No big deal, just edit the Application.less to find it (@import '../bootstrap/bootstrap.less'; ) It also imports jquery which we need later anyway. (Just upgrade jquery to 3.1.1)


    005 Stubbing out our Users Admin
    No problems at all with this video.

    ......

    008 Entity Framework with ASP.NET MVC
    No problems at all with this video using the latest NuGet packages for BCrypt, MySql.Data.Entities, and EntityFramework.
    Nelson didn't cover installing MySQL server and Workbench but if you need it, he's talked about it in other videos.

    009 ASP.NET Auth
    No problems at all with this video.
    Last edited by oldngrey; 03-03-2017 at 01:21 AM.

  3. #3
    Join Date
    Nov 2006
    Location
    Vancouver, WA
    Posts
    211
    Quote Originally Posted by oldngrey View Post
    Video 4 - 004 Setting up our Website

    This is where things get awkward.
    I first tried installing the latest versions of BundleTransformer.Less and JavaScriptEngineSwitcher.V8
    But both fail unless I use older versions: no later than 1.5.8 for the .V8 package and 1.9.92 for the .Less package.

    Now I have to ask myself the question: do I try to figure it out or do I try and stay at Nelson's code?
    For the time being, I have taken the easy way out and just kept the versions mentioned above.
    Yea I had the same problem but I kept the latest versions of both and ended up just adding the htlm links in my code to get it to work.

  4. #4
    Join Date
    Feb 2014
    Posts
    201
    010 Hooking up our Users Admin to the Database
    Now this is an odd one. I am using the latest bootstrap (v3.3.7).

    The code ran fine but had a glitch when showing the roles when you edit or create a user. The checkbox would show up in the middle of the label following it rather than before it. ie the checkbox seemed to be displayed at the same screen co-ordinates as the label but each having their own left-margin.
    When I looked at the Bootstrap website they were using "radio" instead of "checkbox" to create buttons. So I edited the UserRole.cshtml file to make the swap, but that gave the button AFTER the role, which is interesting because that's the order they appear in the UserRole.cshtml file.

    So here's a working file with the label and button lines swapped and with radio replacing checkbox. It appears to work (at least in this video! It will be interesting to see what happens when Navbars are used. I have the feeling this will be real fun.)


    Code:
    @model BuzzMMO.Web.Areas.Admin.ViewModels.UserRole
    
    <div class="radio">
        @Html.HiddenFor(f => f.Id)
        @Html.HiddenFor(f => f.Name)
    
    
        @Html.EditorFor(f => f.IsSelected)
        @Html.LabelFor(f => f.IsSelected, Model.Name)
    </div>
    Last edited by oldngrey; 02-18-2017 at 12:07 AM.

  5. #5
    Join Date
    Aug 2010
    Posts
    108
    I replaced all of the less files with v3.3.7 of bootstrap to test this on my end and the checkbox works correctly. Granted I am still using the same bundle transformer and V8 engine as before.

    Code:
    @model MMO.Web.Areas.Admin.ViewModels.UserRole
    
    <div >
        @Html.HiddenFor(f => f.Name)
        @Html.HiddenFor(f => f.Id)
    
        @Html.CheckBoxFor(f => f.IsSelected)
        @Html.LabelFor(f => f.IsSelected, Model.Name)
    </div>

  6. #6
    Join Date
    Feb 2014
    Posts
    201
    Interesting. I mis-read "radio", I should be sticking with "checkbox" so we can select more than 1 in the list. Stupid noob mistake.
    We do agree on the order of your lines 6 and 7 though. Nelson has them swapped.
    Your use of CheckBoxFor has the roles bold on mine.

    To stop the bold and align it without any css selectors I found this worked:

    Code:
    @model BuzzMMO.Web.Areas.Admin.ViewModels.UserRole
    
    <div class="checkbox">
        <label>
            @Html.HiddenFor(f => f.Id)
            @Html.HiddenFor(f => f.Name)
    
            @Html.EditorFor(f => f.IsSelected)
            @Html.LabelFor(f => f.IsSelected, Model.Name)
        </label>
    </div>
    How much of this is science and how much is art?
    Last edited by oldngrey; 01-28-2017 at 05:32 PM.

  7. #7
    Join Date
    Feb 2014
    Posts
    201
    011 Finish User Admin
    No problems in this video using jquery-3.1.1

    012 Roles Based Authentication
    No problems at all with this video.
    Last edited by oldngrey; 01-29-2017 at 09:53 PM.

  8. #8
    Join Date
    Feb 2014
    Posts
    201
    013 User Registration
    I have previously had problems with this video, because of the NuGet packages Nelson uses. It all goes well until the 40'19 mark.
    Nelson then installs the MVCMailer NuGet package which is tied to T4.Scaffolding.Core v1.00 which is incompatible with Visual Studio 2017. Even though there are later versions of T4.Scaffolding, MVCMailer seems to insist on installing and using v1.00 even if you ask for the latest dependency version and not the lowest. Oh well......

    In the past I have ignored MVCMailer and installed Postal instead. However, if you NEVER run the Scaffold command you can use MVCMailer because the only thing the Scaffold command does is to create 4 files. The video shows the filenames clearly, and so we can simply create them ourselves. Nelson edits each of the files in turn so there are no problems.

    Here is the link to use Postal instead: https://www.3dbuzz.com/forum/threads...ghlight=Postal - see post #13

    After that little mess, sending and activating the account works as per the video. Just NEVER run the Scaffold command in the Package Manager Console. And I mean NEVER. If it's ever run, even inadvertently, then PMC will give an init error each time it's run after opening Visual Studio.

    014 User Password Reset
    No problems at all with this video - if the previous one worked, this one should too.

    015 - Fixing Admin Account
    No problems at all with this video.

    016 Deploy Tokens
    No problems at all with this video.

    017 Web API.mp4
    No problems with this video except that Postman has changed a bit. It's now a standalone app and not a browser tab. All the buttons are still there but re-arranged.

    ....

    019 Implementing Polymorphic Entities
    No real problems in this video. If you don't use the add-migration command until Nelson finally gets it working, you can save a lot of effort deleting migrations and rolling back the database.

    020 Upload API
    The only problem I had with this video was getting the new improved Postman to display something when I hit F12. It's disabled by default and when you google it to find out how to enable it (not hard - google search for "postman enabling inspect") it becomes right-click "Inspect" and not F12 any more. And once again it opens in a separate window rather than split the current view in Postman.

    021 Finalize Upload API
    No problems with this video. In fact, they are rather good fun!

    022 Roles Admin
    No problems with this video.
    Last edited by oldngrey; 03-12-2017 at 06:57 AM.

  9. #9
    Join Date
    Feb 2014
    Posts
    201
    023 Game Settings
    No problems with this video - providing you watch it from the 42'39 mark before you start and note the bugfix that will save a bit of time deleting migrations and making blanks migrations etc.
    I've been watching each video before I open Visual Studio. In that way I've avoided quite a few problems.

    024 Authorization API #1
    Watching the video before doing the coding really helped in this vid. If you edit the MMODatabaseContext.cs file as per 22'05 before you do your first add-migration, then it will work first time.

    025 Authorization API #2
    No problems with this video apart from my mis-typing a jason request in postman....

    026 Configuring IIS and SSL
    No problems adding IIS to Windows 10 pro.
    Adding a self-signed certificate was a little bit easier using "pluralsight Self Signed Certificate" instead of the older iis6 resource kit that Nelson used.
    Last edited by oldngrey; 02-22-2017 at 09:49 PM.

  10. #10
    Join Date
    Nov 2006
    Location
    Vancouver, WA
    Posts
    211
    Quote Originally Posted by oldngrey View Post
    023 Game Settings
    026 Configuring IIS and SSL
    No problems adding IIS to Windows 10 pro.
    Adding a self-signed certificate was a little bit easier using "pluralsight Self Signed Certificate" instead of the older iis6 resource kit that Nelson used.
    What is pluralsight and where do I get info.
    The only way to fail is to give up or die...

Page 1 of 3 123 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •