SC2Mapster Forums

Development > Data

No Texture on unit when built

  • 17 posts
    #1 Feb 11, 2012 at 17:31 UTC - 0 likes

    I have added a texture to the Void Ray.

    If I place a Void Ray in the editor and try the map, the new texture is on the unit in game.

    But when a train a Void Ray from the Stargate on the same map, the ordinary texture is still on!

    So I get two Void Rays, one with the new texture on and one with the old texture. Even thought they are both the same kind of unit!

    How can this be fixed?

    #2 Feb 11, 2012 at 18:36 UTC - 0 likes

    what are you using as your event to trigger the TextureSelectByID?

    If you are using Actor Creation -> TextureSelectByID, perhaps try a UnitBirth.VoidRay -> TextureSelectByID

    #3 Feb 11, 2012 at 18:50 UTC - 0 likes

    @BorgDragon: Go

    I have followed your tutorial: http://www.sc2mapster.com/forums/resources/tutorials/20772-data-actor-events-message-texture-select-by-id/

    I´ve done it 3 times now, with the same results every time.

    I´ve tried to change unitBirth.Voidray - Textureselect by ID

    Does not work either : /

    As soon as I build VoidRay in Stargate, they pop with old skin.

    This is the texture I try to import: http://www.sc2mapster.com/assets/dark-protoss/files/11-warp-ray/

    Last edited Feb 11, 2012 by Kabelkorven
    #4 Feb 11, 2012 at 21:49 UTC - 0 likes

    Very odd.... I just tried it with marines and I'm having no problems. Preplaced or popping from the barracks.

    I'll download that texture and see if I can get the vray to work...

    EDIT:: Very odd... I tried the same exact thing with the void ray but when it comes out of the stargate, it's still silver...

    EDIT2:: SOLVED!!!!!!!!

    OK. So because the VoidRay gets WARPED IN from the warpgate FIRST, what you basically need to do, is create the Diffuse Texture(main.diffuse) and Specular Texture(main.specular) as normal.

    For the models, add the SAME declarations to the "Void Ray" AND "Void Ray Warp In Stargate" models. They both have the same texture paths (VoidRay_Diffuse & VoidRay_Specular). Make sure that both of those models' Texture Declarations+ fields are identical. So, you can basically setup the Void Ray, and then just copy/paste the entire Declarations+ to the Warp In Stargate model.

    Then, just add to the "Void Ray Warp In Stargate" actor, Actor Creation -> Texture SelectByID Diffuse/Specular(aswell as to the Void Ray actor).

    It then works fully in game.

    I would imagine if you wanted to swap textures on any Protoss Unit that is warpable, that you would have to do the same to their warpin models if you plan to be able to build them aswell and keep the texture.

    And... attached the file, just for the sake of it.

    You will notice that I use different paths for the textures due to testing, before I realised the thing about the warpin. But yes, it works eitherway.

    Last edited Feb 11, 2012 by BorgDragon
    Name Size MD5
    vray_tex_replace_test.SC2Map 226.1 KiB 01102157c371...
    #5 Feb 11, 2012 at 23:43 UTC - 0 likes

    Heh, I could have saved you some time here; stumbled across the same thing when making the box :)

    http://img577.imageshack.us/img577/4226/blaj.jpg

    #6 Feb 11, 2012 at 23:47 UTC - 0 likes

    @Kueken531: Go

    Well, it didn't take too much time, From first posting to final edit, it took about 25 minutes or so. It was just realizing that the Warp In visual also includes the unit that made me go "Oh right".

    I had noticed that previously, but it didn't dawn on me at first.

    #7 Feb 12, 2012 at 19:57 UTC - 0 likes

    I´ve done everything you have described and I have looked in your map... I get the same error every time I load up my map in the editor:

    [2/12/2012 8:54:12 PM] Warning: Could not find texture file Assets\Textures\WarpRayDiffuse.dds in texture entry WarpRayDiffuse. [2/12/2012 8:54:12 PM] Warning: Could not find texture file Assets\Textures\WarpRaySpecular.dds in texture entry WarpRaySpecular. [2/12/2012 8:54:12 PM] Warning: CActorUnit[VoidRay] Has event without a triggering message. Event[Terms "" Send ""] [2/12/2012 8:54:12 PM] Warning: [ 633 1] CActorUnit[VoidRay] VoidRay Assets\Units\Protoss\VoidRay\VoidRay.m3; Could not find texture with id WarpRayDiffuse and expression <None>. [2/12/2012 8:54:12 PM] Warning: [ 634 1] CActorUnit[VoidRay] VoidRay Assets\Units\Protoss\VoidRay\VoidRay.m3; Could not find texture with id WarpRayDiffuse and expression <None>.

    Everything looks like it should in the tutorial + the way you described it in the post above. None of the imported textures appears at all...

    What on earth am I doing wrong?

    T_T

    Ps. This error message appears in game when I build a void ray:

    Units\Protoss\VoidRay\VoidRay.m3; Could not find texture with ID WarpRayDiffuse and expression <none>

    Last edited Feb 12, 2012 by Kabelkorven
    #8 Feb 12, 2012 at 20:17 UTC - 0 likes

    Looks like you forgot to set the slots on the textures.

    #9 Feb 12, 2012 at 20:39 UTC - 0 likes
    Quote from DrSuperEvil: Go

    Looks like you forgot to set the slots on the textures.

    I found out! I´ve been doing all my changes in a mod. The map that I alwasys test the MOD on had the actors messed up. (I´ve must been in the void ray actor to try to fix it in the map and then saved it.) When I made my test map standard again, the settings from the MOD now works. The unit has textures on it.

    But there is still one small problem, every time I click on "Train Void Ray" on the stargate this red error message appears in game: WARNING: [31 5] CActorModel[V... The Void Ray has the new textures on atleast.

    I will try to find what causes the error. But perhaps someone here knows?

    Last edited Feb 12, 2012 by Kabelkorven
    #10 Feb 12, 2012 at 21:52 UTC - 0 likes

    @Kabelkorven: Go

    Hmm, there could be any number of reasons for that error... are you applying the same texture more than once?

    There are MANY error codes for Actor errors. In the end, however, at least it works, with a slight, minor annoyance no doubt.

    Are you able or willing to post the map? I would gladly take a look at the actor for you and trouble shoot the error.

    #11 Feb 12, 2012 at 23:05 UTC - 0 likes

    Just a reminder for everyone, it's always a good idea to double check your events+ with a fine comb.

    Problem solved, was using an improper actor Event to setup the Texture, IE

    • TextureSelectByID
      • TextureSelectByID VRay_Spec

    Should be something closer along the lines of

    • TimerExpired
    • ActorCreation

    Many other possibilities

    Last edited Feb 12, 2012 by BorgDragon
    #12 Jul 13, 2012 at 16:15 UTC - 0 likes

    Now I have encountered the same problem with an other texture: http://www.sc2mapster.com/assets/dark-protoss/files/47-templar-stalker/

    Everything works when I build it from a gateway. When I warp it in, this red error message appears in game: "No mapping for slot main.diffuse." And a lot of numbers and symbols next to the text.

    It does not happen when I build it from the gateway! Only on warp in!

    I apply the new skin via texture declarations to the "Stalker warp in model" but still it does not work.

    Any idea what the problem might be this time?

    Last edited Jul 13, 2012 by Kabelkorven
    #13 Jul 14, 2012 at 11:15 UTC - 0 likes

    No one knows?

    #14 Jul 14, 2012 at 13:50 UTC - 0 likes

    I dont know what you did, but it was the exact same thing as the VRay. I looked at the Actor for the Stalker, looked at the model it used for Warp Ins, modified that and the base Stalker models, and bam. It works no problems, no errors.. Here's the same map as the gold Void Rays, with the addition of the Gold Stalkers.

    Last edited Jul 14, 2012 by BorgDragon
    Name Size MD5
    vray_tex_replace_test.SC2Map 1.1 MiB f2d82873fe1f...
    #15 Dec 28, 2012 at 22:52 UTC - 0 likes

    Aye It will be a huge necro, but I tried to aply the Warp Ray texture in my mod, and got the "No mapping for slot main.diffuse." error massage, also i downloaded the test map here and in the test map i also get the No mapping for slot main.diffuse. Any one know what is the problem?

    Chronicles of Azeroth - Brave heroes, walk again in the land of Azeroth, with the remake of warcraft 1,2,3 and new episodes based on world of warcraft lore- Temple of Ahn'Qiraj, Burning Crusade, Wrath of the Lich King, Cataclysm.

    #16 Dec 28, 2012 at 23:54 UTC - 0 likes

    Sure you have the _ in the right spots and the capitalization is correct? You used the full texture name for both the declaration and the trigger on string?

    #17 Dec 29, 2012 at 09:42 UTC - 0 likes

    @DrSuperEvil: Go

    i checked thousand times but does not found any problem with spots and other things, i also did the Carrier->Tempest and that work fine. Interesting now i tested my map and it work fine without any change. Weird.

  • 17 posts

You must login to post a comment. Don't have an account? Register to get one!