[Release] .Net 3d modelviewer control menu

User Tag List

Results 1 to 6 of 6
  1. #1
    Allstar .ιllιlı.'s Avatar Banned
    Reputation
    284
    Join Date
    Jan 2009
    Posts
    481
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [Release] .Net 3d modelviewer control

    .Net 3d modelviewer
    -------------------------
    By: Allstar

    The idea:
    So, I was kinda' bored and wanted to continue my "WoW Creature Creator" application, but it seems I deleted the source code and I don't want to re-begin programming. So creating this control takes me (or you) one step closer to a good wow application.

    Anyway, that's not important. I just created this control so that you guys can "easily" use a modelviewer for your .net applications.


    NOTE: My control has only been tested with C#.net 3.5

    The possibilities:
    So, what can you do with it?
    Well, pretty much the same you can do with WoWhead's 3d modelviewer.

    - Support for one model:


    Code for one model:
    Code:
    modelviewer1.SetModel("39107", (int)Modelviewer.modeltype.Weapon);
    Explanation:
    With .setmodel you can display a single model on the modelviewer. It requires 2 parameters. The first parameter is a string, it represents the DISPLAY-ID of the model. The second parameter is an integer and It's the modeltype. In this example I used enums to make it easier to code, though you can use simple integers as well.

    The enums are as following:
    Code:
    Weapon = 1,
    Armor = 2,
    NPC = 8,
    EquipedArmor = 16


    - Support for multiple models that can be equiped (such as armor and weapons):



    Code for equipable models:
    Code:
    modelviewer1.SetModelForEquip("draenei", "female", equiplist_string);
    Explanation:
    With .SetModelForEquip you start the render of multiple equipable items.
    This function requires 3 parameters.
    - The first parameter is a string and represents the race you want to show. This is a simple string without caps, and no spaces.
    - The second parameter is also a string and represents the gender of the displayed character (either "male" or "female").
    - The third parameter is a bit more tricky. This is the list of items the character will be wearing:
    Code:
    string[] equiplist = { Convert.ToString((int)Modelviewer.slot.Head), "15322", Convert.ToString((int)Modelviewer.slot.Offhand), "48339", "5", "13116", "7", "13117", "4", "13115" };
    string equiplist_string = String.Join(",", equiplist);
    It's easier then it looks. The first entry of the array is a string containing the slot-id. Again you can either use the enums or a number (don't forget to convert to string!) as you can see in the example.

    The enums:
    Code:
    Ammo = 0,
    Head = 1,
    Neck = 2,
    Shoulder = 3,
    Shirt = 4,
    Chest = 5,
    Belt = 6,
    Legs = 7,
    Feet = 8,
    Wrist = 9,
    Gloves = 10,
    Finger1 = 11,
    Finger2 = 12,
    Trinket1 = 13,
    Trinket2 = 14,
    Back = 15,
    MainHand = 16,
    Offhand = 17,
    Ranged = 18,
    Tabard = 19
    The second entry is the DISPLAY-ID of the model you want the character to wear.

    So basically an itemlist should look like: (slot, displayid, slot, displayid, ...)

    The last line in the example above just puts everything in that is in the array in one string where all items are separated by a ",".

    Well, that's kinda' everything for now. Please note that it's still unfinished and that features will be added.

    Anyways, I hope you guys can use this.

    ~Allstar


    Download link:

    Code:
    http://www.michieldemey.be/modelviewerdotnet_example.zip

    [Release] .Net 3d modelviewer control
  2. #2
    Dombo's Avatar Banned
    Reputation
    622
    Join Date
    Nov 2008
    Posts
    1,421
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Very nice for those who would like to integrate this with their .NET project.

  3. #3
    solttu's Avatar Member
    Reputation
    1
    Join Date
    Aug 2008
    Posts
    6
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I can't get the example work :S. I get error Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)) at this.modelviewer1 = new Wowhead_Controls.Modelviewer();

  4. #4
    maclone's Avatar / Authenticator enabled
    Reputation
    2420
    Join Date
    Nov 2007
    Posts
    8,726
    Thanks G/R
    0/1029
    Trade Feedback
    0 (0%)
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    I expected to see a real wowhead like model viewer, but...
    Zomfg. And no, don't ask. - Dombo did it.

  5. #5
    Allstar .ιllιlı.'s Avatar Banned
    Reputation
    284
    Join Date
    Jan 2009
    Posts
    481
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by solttu View Post
    I can't get the example work :S. I get error Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)) at this.modelviewer1 = new Wowhead_Controls.Modelviewer();
    Do you by any chance have a 64-bit OS? Try compiling for a 32-bit system. (x86)

    Originally Posted by maclone View Post
    I expected to see a real wowhead like model viewer, but...
    It's wowhead's genuine model viewer. What more do you want?

  6. #6
    [Sadistic]'s Avatar Member
    Reputation
    42
    Join Date
    Sep 2009
    Posts
    247
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    oh this is neato nice work

Similar Threads

  1. [Release] Scan Pixels function for VB.net
    By suicidity in forum World of Warcraft Bots and Programs
    Replies: 6
    Last Post: 07-09-2014, 02:12 PM
  2. [Release][Tool] PoE Particle control[say bb to poison cloud]
    By Wrongusername in forum PoE Bots and Programs
    Replies: 18
    Last Post: 05-21-2014, 11:49 PM
  3. [Release] Control Panel + a
    By nbhfam in forum World of Warcraft Emulator Servers
    Replies: 3
    Last Post: 06-01-2008, 05:35 PM
  4. [RELEASE] GamerzWoW Launcher - VB9.NET Source!
    By whitekidney in forum World of Warcraft Bots and Programs
    Replies: 9
    Last Post: 04-26-2008, 03:59 PM
  5. [RELEASE] GamerzWoW Launcher - VB9.NET Source!
    By whitekidney in forum WoW EMU Programs
    Replies: 0
    Last Post: 04-26-2008, 11:48 AM
All times are GMT -5. The time now is 02:59 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search