Forum > Serverside Modding
[QUESTION] Different Race backgrounds on Char creation/selec
(1/1)
spiderwaseem:
Hello!
For the past couple of hours, I've been trying to make a race (Orc, ID 2) have a different character creation screen background, than it's character selection screen. I failed several times to do so.
I use the following code in GlueParent.lua to set a character creation background:
--- Quote --- if ( name == "Orc" or "ORC" ) then name = "Orc"; end --- End quote ---
The code above signifies that ["Orc" or "ORC"] are representing which race to set the background for. And [name = "Orc";] sets which background model to set for the race.
This is also within the same function which allows me to just say the UI Backgrounds name instead of "UI_...." :
--- Quote --- local nameupper = strupper(name); local path = "Interface\Glues\Models\UI_"..name.."\UI_"..name..".m2"; if ( model == CharacterCreate ) then SetCharCustomizeBackground(path); else SetCharSelectBackground(path); end --- End quote ---
I believe this code isn't new to anyone here, but I'm providing as much info as possible, to recieve as much info as possible.
---- Now, what I'm trying to do is make the Orc race have 2 different backgrounds for 2 different occasions. 1 Background on the Character Creation screen, then a different background on the Character Selection Screen.
I tried the following code in GlueParent.lua, under the following function:
function SetBackgroundModel(model, name)
--- Quote --- if ( name == "Orc" or "ORC" and CharacterCreate_Finish(true)) then name = "Human"; end --- End quote ---
The above didn't work, so I've tried the following:
--- Quote --- if ( name == "Orc" or "ORC" and CharacterCreate_Finish(true)) then SetCharCustomizeBackground("Interface\Glues\Models\UI_Human\UI_Human.m2"); end --- End quote ---
That didn't work either.
In total, I tried to use similar code on "OnShow" or similar functions. Overall, I edited GlueParent.lua, CharacterSelect.lua and CharacterCreate.lua. I didn't really get anywhere.
In conclusion, I'm asking for help from anyone here who can write a lua code for WoW 3.3.5 that can cause a race (Orc, ID: 2) to have 2 different backgrounds. 1 On the Character Creation screen, and one on Character Selection.
Thanks for everyone's time who read and will help. :)
Kaev:
This is client modding, not serverside modding. :P And this won't fix the problem, but maybe problems in the future:
--- Code: ---if ( name == "Orc" or name == "ORC" and CharacterCreate_Finish(true)) then
--- End code ---
You had name == "Orc" or "ORC" instead of name == "Orc" or name == "ORC".
spiderwaseem:
--- Quote from: "Kaev" ---This is client modding, not serverside modding. :P And this won't fix the problem, but maybe problems in the future:
--- Code: ---if ( name == "Orc" or name == "ORC" and CharacterCreate_Finish(true)) then
--- End code ---
You had name == "Orc" or "ORC" instead of name == "Orc" or name == "ORC". --- End quote ---
Thanks for the heads up on that. :)
If anyone can help on this issue, thought, that would be great!
Navigation
[0] Message Index
|