Johnnyprofane Posted November 11, 2013 Share Posted November 11, 2013 The title pretty much sums it up. How do I do this thing? Please and thank you I couldn't find it in the artist guides, but I could've sworn there's a way since the last update. Link to comment Share on other sites More sharing options...
Malacath Posted November 11, 2013 Share Posted November 11, 2013 Assuming you know how to convert images it's easy. The image should have 64x64 in dimension and then you'll want to add in modmainAssets = { Asset("IMAGE", "minimap/myicon.tex"), Asset("ATLAS", "minimap/myicon.xml"),}AddMinimapAtlas("minimap/myicon.xml")And in the prefab in question you'll add the follwinglocal fucntion fn(Sim) --This already exists in some form --Stuff that was already here local minimap = inst.entity:AddMiniMapEntity() minimap:SetIcon( "myicon.tex" )end Link to comment Share on other sites More sharing options...
Johnnyprofane Posted November 11, 2013 Author Share Posted November 11, 2013 Fantastic! Thanks so much. Im not at my computer and assumed the process would be about that but couldn't test it. Seeing as I wasn't going to be able to till tonight I figured it wouldn't hurt to have someone awesome who knows already confirm things for me. You're the best! Link to comment Share on other sites More sharing options...
Developer Cheerio Posted November 11, 2013 Developer Share Posted November 11, 2013 Assuming you know how to convert images it's easy. The image should have 64x64 in dimension and then you'll want to add in modmainAssets = { Asset("IMAGE", "minimap/myicon.tex"), Asset("ATLAS", "minimap/myicon.xml"),}AddMinimapAtlas("minimap/myicon.xml")And in the prefab in question you'll add the follwinglocal fucntion fn(Sim) --This already exists in some form --Stuff that was already here local minimap = inst.entity:AddMiniMapEntity() minimap:SetIcon( "myicon.tex" )endIf you ever want to set one of these up as an example, I'll be happy to post it to the guides thread. Link to comment Share on other sites More sharing options...
Malacath Posted November 11, 2013 Share Posted November 11, 2013 If you ever want to set one of these up as an example, I'll be happy to post it to the guides thread.Sounds like a good idea. I'll summon you when I've done it (or PM you, I don't know what you prefer), will probably not be today though. Link to comment Share on other sites More sharing options...
Malacath Posted November 12, 2013 Share Posted November 12, 2013 It's a simple thing but anyways, upon Cheerios suggestion I uploaded a Sample Mod for this.Cheerio I hereby summon thee to do as thouh wishes with this mod. Link to comment Share on other sites More sharing options...
Fidooop Posted February 7, 2014 Share Posted February 7, 2014 Hey, I tried this and it gave me an error saying ')' expected near 'searchlite'Have any idea what I did wrong? Link to comment Share on other sites More sharing options...
MidrealmDM Posted April 1, 2014 Share Posted April 1, 2014 Hey, I tried this and it gave me an error saying ')' expected near 'searchlite'Have any idea what I did wrong? I wish I could tell you, but I followed the instructions and it worked perfectly. Did you create the <myicon>.tex and <myicon>.xml files in the minimap folder of your mod? Link to comment Share on other sites More sharing options...
Fidooop Posted April 1, 2014 Share Posted April 1, 2014 I wish I could tell you, but I followed the instructions and it worked perfectly. Did you create the <myicon>.tex and <myicon>.xml files in the minimap folder of your mod?my post was feb 6th... I've learned alot since then! XD(in other words I now have a character that has 2 different minimap icons and switches between them when he puts his hat on!!!) Link to comment Share on other sites More sharing options...
Dudedude Posted April 6, 2014 Share Posted April 6, 2014 Assuming you know how to convert images it's easy. The image should have 64x64 in dimension and then you'll want to add in modmainAssets = { Asset("IMAGE", "minimap/myicon.tex"), Asset("ATLAS", "minimap/myicon.xml"),}AddMinimapAtlas("minimap/myicon.xml")And in the prefab in question you'll add the follwinglocal fucntion fn(Sim) --This already exists in some form --Stuff that was already here local minimap = inst.entity:AddMiniMapEntity() minimap:SetIcon( "myicon.tex" )endI did this, but it crashes whenever I select my mod! Can you tell me what I'm doing wrong?Assets = { Asset( "ATLAS", "images/saveslot_portraits/ebsol.xml" ), Asset( "IMAGE", "images/saveslot_portraits/ebsol.tex" ), Asset( "ATLAS", "images/selectscreen_portraits/ebsol.xml" ), Asset( "IMAGE", "images/selectscreen_portraits/ebsol.tex" ), Asset( "ATLAS", "images/selectscreen_portraits/ebsol_silho.xml" ), Asset( "IMAGE", "images/selectscreen_portraits/ebsol_silho.tex" ), Asset( "ATLAS", "bigportraits/ebsol.xml" ), Asset( "IMAGE", "bigportraits/ebsol.tex" ), Asset("IMAGE", "minimap/ebsolicon.tex"), Asset("ATLAS", "minimap/ebsolicon.xml"), AddMinimapAtlas("minimap/ebsolicon.xml")} Link to comment Share on other sites More sharing options...
MidrealmDM Posted April 6, 2014 Share Posted April 6, 2014 I did this, but it crashes whenever I select my mod! Can you tell me what I'm doing wrong?Assets = { Asset( "ATLAS", "images/saveslot_portraits/ebsol.xml" ), Asset( "IMAGE", "images/saveslot_portraits/ebsol.tex" ), Asset( "ATLAS", "images/selectscreen_portraits/ebsol.xml" ), Asset( "IMAGE", "images/selectscreen_portraits/ebsol.tex" ), Asset( "ATLAS", "images/selectscreen_portraits/ebsol_silho.xml" ), Asset( "IMAGE", "images/selectscreen_portraits/ebsol_silho.tex" ), Asset( "ATLAS", "bigportraits/ebsol.xml" ), Asset( "IMAGE", "bigportraits/ebsol.tex" ), Asset("IMAGE", "minimap/ebsolicon.tex"), Asset("ATLAS", "minimap/ebsolicon.xml"), AddMinimapAtlas("minimap/ebsolicon.xml")} Take the AddMiniMapAtlas line out of the brackets egAssets = { Asset( "ATLAS", "images/saveslot_portraits/ebsol.xml" ), Asset( "IMAGE", "images/saveslot_portraits/ebsol.tex" ), Asset( "ATLAS", "images/selectscreen_portraits/ebsol.xml" ), Asset( "IMAGE", "images/selectscreen_portraits/ebsol.tex" ), Asset( "ATLAS", "images/selectscreen_portraits/ebsol_silho.xml" ), Asset( "IMAGE", "images/selectscreen_portraits/ebsol_silho.tex" ), Asset( "ATLAS", "bigportraits/ebsol.xml" ), Asset( "IMAGE", "bigportraits/ebsol.tex" ), Asset("IMAGE", "minimap/ebsolicon.tex"), Asset("ATLAS", "minimap/ebsolicon.xml"),} AddMinimapAtlas("minimap/ebsolicon.xml") And then make sure the following line is in your <character>.lua inst.MiniMapEntity:SetIcon( "ebsolicon.png" ) it should be placed somewhere within local fn = function(inst) eglocal fn = function(inst) -- [other items may be in this area as well] inst.MiniMapEntity:SetIcon( "ebsolicon.png" ) end Link to comment Share on other sites More sharing options...
Dudedude Posted April 7, 2014 Share Posted April 7, 2014 Ok, ok. I'm doing what you told me to do, but the minimap icon is just blank. I'm not sure what the problem is. Does it have something to do with where I'm placing the files. At the moment, they're in the images folder. I'll also show you what I've got in terms of what you told me to do.In the Modmain:Assets = { Asset( "ATLAS", "images/saveslot_portraits/ebsol.xml" ), Asset( "IMAGE", "images/saveslot_portraits/ebsol.tex" ), Asset( "ATLAS", "images/selectscreen_portraits/ebsol.xml" ), Asset( "IMAGE", "images/selectscreen_portraits/ebsol.tex" ), Asset( "ATLAS", "images/selectscreen_portraits/ebsol_silho.xml" ), Asset( "IMAGE", "images/selectscreen_portraits/ebsol_silho.tex" ), Asset( "ATLAS", "bigportraits/ebsol.xml" ), Asset( "IMAGE", "bigportraits/ebsol.tex" ), Asset("IMAGE", "minimap/ebsolicon.tex"), Asset("ATLAS", "minimap/ebsolicon.xml"), AddMinimapAtlas("minimap/ebsolicon.xml")} In the Prefab file:local fn = function(inst) -- choose which sounds this character will play inst.soundsname = "wilson" -- a minimap icon must be specified inst.entity:AddMiniMapEntity() inst.MiniMapEntity:SetIcon("ebsolicon.png") Somehow, it still refuses to work. This is so frustrating!! Link to comment Share on other sites More sharing options...
debugman18 Posted April 7, 2014 Share Posted April 7, 2014 Ok, ok. I'm doing what you told me to do, but the minimap icon is just blank. I'm not sure what the problem is. Does it have something to do with where I'm placing the files. At the moment, they're in the images folder. I'll also show you what I've got in terms of what you told me to do.In the Modmain:Assets = { Asset( "ATLAS", "images/saveslot_portraits/ebsol.xml" ), Asset( "IMAGE", "images/saveslot_portraits/ebsol.tex" ), Asset( "ATLAS", "images/selectscreen_portraits/ebsol.xml" ), Asset( "IMAGE", "images/selectscreen_portraits/ebsol.tex" ), Asset( "ATLAS", "images/selectscreen_portraits/ebsol_silho.xml" ), Asset( "IMAGE", "images/selectscreen_portraits/ebsol_silho.tex" ), Asset( "ATLAS", "bigportraits/ebsol.xml" ), Asset( "IMAGE", "bigportraits/ebsol.tex" ), Asset("IMAGE", "minimap/ebsolicon.tex"), Asset("ATLAS", "minimap/ebsolicon.xml"), AddMinimapAtlas("minimap/ebsolicon.xml")} In the Prefab file:local fn = function(inst) -- choose which sounds this character will play inst.soundsname = "wilson" -- a minimap icon must be specified inst.entity:AddMiniMapEntity() inst.MiniMapEntity:SetIcon("ebsolicon.png") Somehow, it still refuses to work. This is so frustrating!! Change png to tex. Link to comment Share on other sites More sharing options...
Dudedude Posted April 7, 2014 Share Posted April 7, 2014 OH MY GOD FINALLY!Thank you so much, guys. The icon is finally showing! SO HAPPY! Now I need to figure out why I didn't figure that out myself... :/You guys are awesome! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.
Please be aware that the content of this thread may be outdated and no longer applicable.