Welcome, Guest. Please login or register.
Did you miss your activation email?
September 19, 2024, 11:50:20 PM
Home Help Login Register
News: Zombie Master 2 discussion

Zombie Master  |  Other  |  Trouble in Terrorist Town  |  Topic: TTT Icon Issue
Pages: [1]
Author Topic: TTT Icon Issue  (Read 21126 times)
Phish
Poster

Posts: 6


« on: February 28, 2012, 05:55:25 PM »

Hi there, new to the forums and (somewhat) new to coding TTT. I've had a server for a while and haven't been able to get the icons to work. Since its a cosmetic problem I put it low on my todos, but recently I have spent HOURS trying to figure it out. I have browsed several forums and post and tried troubleshooting methods described in them but to no avail. I'm finally ready to bring the issue to the pros.

I have a few custom sweps. They all work perfectly except for the icons. I had my gfx artist make some icons. I stressed how important it was to follow the guide step by step from badking.net, and not to miss a single instruction (format, etc).
I got the vtfs from him and uploaded it via ftp to my garrysmod/materials/vgui/ttt folder (NOT the vgui/ttt folder in the gamemodes/terrortown, fyi).

I then created a file with the same name, .vmt, and added the lines provided in the tutorial with the correct pathname, using icon_armor.vmt as a template.

I then added the resource.addfile lines to the resources.lua (format identical to the ones already provided by BK.

Right now it is constantly asking me to download the files everytime I join., and the icons ofc dont work

Here the line from my resource.lua:
resource.AddFile("materials/VGUI/ttt/icon_zeph_minigun.vmt")
icon_zeph_minigun.vmt (and .vtf) are in materials/VGUI/ttt/

I says it is downloading materials/VGUI/ttt/icon_zeph_minigun.vmt, and materials/VGUI/ttt/icon_zeph_minigun.vtf.bz2 (or something like that) everytime I join

UPDATE:

I manually added teh vtf and vmts to my personal directory and they work (this didnt happen before, but i changed some coding)

The filenames/directory are still the same however, and they will not work with my fast DL. The keep redownloading for everyone else.  Websyncing (NFO servers) will add the files to my fast DL site (http://lethalaggression.site.nfoservers.com/server).

I dont know why it wont download for them, any ideas?
« Last Edit: February 28, 2012, 06:10:28 PM by Phish »
Mr. Gash
Poster

Posts: 382


www.nonerdsjustgeeks.com


« Reply #1 on: February 28, 2012, 09:05:47 PM »

It's because you put them in "vgui/ttt/". Take them out of the "ttt" folder and put them somewhere else, then it should work.
Phish
Poster

Posts: 6


« Reply #2 on: February 28, 2012, 09:58:43 PM »

It's because you put them in "vgui/ttt/". Take them out of the "ttt" folder and put them somewhere else, then it should work.


Thanks for the response Mr. Gash.
I moved the icons to garrysmod/materials/vgui/LA
Sounds to: garrysmod/sound/LA

I changed the resource locations for all icons and sounds. It DID download the sounds, but when using the spidy gun in game I get:
Failed to load sound "to_far.wav", file probably missing from disk/repository (FOR ALL SPIDY SOUNDS)

The icons are doing the samething, re-"downloading" each rejoin while not truly downloading it
Mr. Gash
Poster

Posts: 382


www.nonerdsjustgeeks.com


« Reply #3 on: February 28, 2012, 10:57:55 PM »

The gun is still trying to play it from the sound/ folder. You need to change the code to play it from sound/LA/ (then again probably just LA/ since it already reads it from the sound/ directory), as for the materials, did you change the lua file that has the resource.AddFile lines to download the materials from the other directory (materials/vgui/LA)?
Phish
Poster

Posts: 6


« Reply #4 on: February 29, 2012, 01:36:39 AM »

The gun is still trying to play it from the sound/ folder. You need to change the code to play it from sound/LA/ (then again probably just LA/ since it already reads it from the sound/ directory), as for the materials, did you change the lua file that has the resource.AddFile lines to download the materials from the other directory (materials/vgui/LA)?


Heres my resource from my spider gun, each resource.addfile is in each gun's shared.lua,a ll like this:
if SERVER then
  AddCSLuaFile( "shared.lua" )
  resource.AddFile("materials/VGUI/LA/icon_zeph_spider.vmt")
end

  SWEP.Icon = "VGUI/LA/icon_zeph_spider"
Phish
Poster

Posts: 6


« Reply #5 on: February 29, 2012, 02:29:10 AM »

I fixed the sounds, the file path in the lua needed a path update, thanks for the idea.

As for the icons, I changed the location of the files to VGUI/LA, instead of vgui/ttt. I changed EVERY line associated with capital VGUI/LA to vgui/la: In the resource.Addfile, Swep.icon lines, and even in the vmts.
Apozen
Poster

Posts: 18


« Reply #6 on: February 29, 2012, 10:16:06 PM »

-sigh-
To fix the "downloading icon but not actually downloading it" problem, you need to do the following:
It seems as if you have a fastdl enabled, if so then it doesn't take items out of the addons folder.
To make it download, place the icons inside materials/vgui/ttt or whatever spot instead of addons.

That worked for me.
Phish
Poster

Posts: 6


« Reply #7 on: March 01, 2012, 06:39:00 AM »

-sigh-
To fix the "downloading icon but not actually downloading it" problem, you need to do the following:
It seems as if you have a fastdl enabled, if so then it doesn't take items out of the addons folder.
To make it download, place the icons inside materials/vgui/ttt or whatever spot instead of addons.

That worked for me.


Did you read my post? it was in said directory. Its not in my addons at all. I fixed it however by creating a servernamed folder in materials, and directing it all to that. Thanks for the help Mr. Gash!
Pages: [1]
Zombie Master  |  Other  |  Trouble in Terrorist Town  |  Topic: TTT Icon Issue « previous next »
Jump to:  


Login with username, password and session length

Powered by SMF 1.1.21 | SMF © 2015, Simple Machines
Page created in 0.008 seconds with 18 queries.