mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-02-05 05:06:24 +00:00
If the first Spray Can you pick up is in a tutorial context and your profile's skincolor is Default, set it to the Spray Can's colour!
Makes Eggman's "what's your favourite colour" line even stronger.
This commit is contained in:
parent
e7bdc073ed
commit
72472d6ae1
1 changed files with 14 additions and 0 deletions
|
|
@ -34,6 +34,7 @@
|
|||
#include "k_battle.h"
|
||||
#include "k_specialstage.h"
|
||||
#include "k_pwrlv.h"
|
||||
#include "k_profiles.h"
|
||||
#include "k_grandprix.h"
|
||||
#include "k_respawn.h"
|
||||
#include "p_spec.h"
|
||||
|
|
@ -784,6 +785,19 @@ void P_TouchSpecialThing(mobj_t *special, mobj_t *toucher, boolean heightcheck)
|
|||
gamedata->spraycans[can_id].map = gamemap-1;
|
||||
mapheaderinfo[gamemap-1]->cache_spraycan = can_id;
|
||||
|
||||
if (gamedata->gotspraycans == 0
|
||||
&& gametype == GT_TUTORIAL
|
||||
&& cv_ttlprofilen.value > 0
|
||||
&& cv_ttlprofilen.value < PR_GetNumProfiles())
|
||||
{
|
||||
profile_t *p = PR_GetProfile(cv_ttlprofilen.value);
|
||||
if (p->color == SKINCOLOR_NONE)
|
||||
{
|
||||
// Apply your favourite colour to the profile!
|
||||
p->color = gamedata->spraycans[can_id].col;
|
||||
}
|
||||
}
|
||||
|
||||
gamedata->gotspraycans++;
|
||||
|
||||
if (!M_UpdateUnlockablesAndExtraEmblems(true, true))
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue