Project Zomboid

Project Zomboid

Spray Paint
DeadlyAccurate 2016 年 2 月 6 日 下午 11:54
Moving the Spray Paint Icon
I figured out how to move the spray paint icon for build 33.

In this folder,
\steamapps\workshop\content\108600\499153179\mods\SprayPaint\media\lua\client\UI
open the spraypaintMenu.lua file in Notepad.

Locate this line:
spraypaintMenu.toolbarButton = ISButton:new(0, craftBtn:getY() + craftBtn:getHeight() + 5, 64, 64, "", nil, spraypaintMenu.showWindowToolbar);

Replace it with this line:
spraypaintMenu.toolbarButton = ISButton:new(0, craftBtn:getY() + craftBtn:getHeight() + 45, 64, 64, "", nil, spraypaintMenu.showWindowToolbar);

Save the file and run PZ.

Additional info:

If you'd like to more precisely line up the icon, change spraypaintMenu.toolbarButton:setDisplayBackground(false);
to
spraypaintMenu.toolbarButton:setDisplayBackground(true);
to see the icon's background. Then, you can play around with a different number besides 45.

Note that I've only figured out how to move the icon. I haven't tested whether the mod still works other than getting the menu to open and close.
< >
正在显示第 1 - 2 条,共 2 条留言
Ryusho Yosei 2016 年 9 月 6 日 下午 7:38 
I can't find this line anywhere in the lua for the menu.
DeadlyAccurate 2016 年 9 月 6 日 下午 9:24 
It's possible the mod has been changed since I posted this fix.
< >
正在显示第 1 - 2 条,共 2 条留言
每页显示数: 1530 50