Skip to content

Commit

Permalink
custom heads: universal loading code (?)
Browse files Browse the repository at this point in the history
by egor0928931
  • Loading branch information
TerminalHash committed Dec 26, 2023
1 parent 25ad9f6 commit 7c8589a
Show file tree
Hide file tree
Showing 108 changed files with 262 additions and 787 deletions.
9 changes: 7 additions & 2 deletions Accolades.as
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "pathway.as"
///////////////////////////////////////////////////////////////////////////////
//
// Accolades system
Expand Down Expand Up @@ -38,7 +39,7 @@ shared class Accolades
Accolades(ConfigFile@ cfg, string _username)
{
username = _username;
customHeadTexture = "../Mods/ctf_gruhsha/Characters/CustomHeads/" + username + ".png";
customHeadTexture = getPath() + "Custom/CustomHeads/" + username + ".png";
array<string> slices;
if(cfg.readIntoArray_string(slices, username))
{
Expand Down Expand Up @@ -126,8 +127,12 @@ shared class Accolades
customHeadExists = doesCustomHeadExists();
}
}
if(CFileMatcher(customHeadTexture).hasMatch())
{
customHeadExists = CFileImage(customHeadTexture).getWidth() == 64;
}
}

bool doesCustomHeadExists()
{
return CFileMatcher(customHeadTexture).getFirst() == customHeadTexture;
Expand Down
Empty file modified Characters/Archer/Archer.cfg
100755 → 100644
Empty file.
Empty file modified Characters/Archer/ArcherAnim.as
100755 → 100644
Empty file.
Empty file modified Characters/Builder/Builder.cfg
100755 → 100644
Empty file.
Empty file modified Characters/Builder/BuilderAnim.as
100755 → 100644
Empty file.
Binary file removed Characters/CustomHeads/egor0928931.png
Binary file not shown.
Binary file removed Characters/CustomHeads/kusaka79.png
Binary file not shown.
Empty file modified Characters/Knight/Knight.cfg
100755 → 100644
Empty file.
Empty file modified Characters/Knight/KnightAnim.as
100755 → 100644
Empty file.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
Binary file added Custom/CustomHeads/Pnext.png
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
Binary file added Custom/CustomHeads/Zazaza64g.png
File renamed without changes
Binary file added Custom/CustomHeads/Zeus.png
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
Binary file added Custom/CustomHeads/kusaka79.png
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
12 changes: 10 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,15 @@
* Кастомные тела для игроков.

## Установка
Создать папку ctf_gruhsha в Mods (King Arthur's Gold/Mods), скопировать файлы из репозитория туда и в mods.cfg вписать название мода (ctf_gruhsha).
Создать папку ctf_gruhsha_v2 в Mods (King Arthur's Gold/Mods), скопировать файлы из репозитория туда и в mods.cfg вписать название мода (ctf_gruhsha_v2).

### Авторы
Skemonde - написал весь основной функционал
Skemonde
* написал весь основной функционал.

egor0928931
* более универсальный способ установки кастомных голов.

TerminalHash
* Англоязычная версия CaptainsMark и смена текстуры при разных языках;
* Кастомные тела путём хардкода в *Anim.as файлах.
Loading

0 comments on commit 7c8589a

Please sign in to comment.