1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.

skin change code problem

Discussion in 'Programming' started by Dtach, Apr 22, 2004.

  1. Dtach

    Dtach ┬░we are the robots

    Joined:
    Mar 22, 2004
    Messages:
    10
    Likes Received:
    0
    Hi this is a little mutator that makes everyone a skelliton and suppose to set skins for red and blue teams but its not working
    so if anyone know a way to fix it or a other way of making it work
    thanks in advance
    --
    Code:
    // Undead Brawl
    class MutUndead extends Mutator;
    #exec OBJ LOAD FILE="..\textures\PlayerSkins.utx"
    #exec OBJ LOAD FILE="..\textures\wm_textures.utx"
    
    event PreBeginPlay()
    {
        SetTimer(0.5,true);
    }
    
    simulated function Timer()
    {
        local Controller C;
        local xPawn x;
    
        for (C = Level.ControllerList; C != None; C = C.NextController)
        {
    	  if (C.Pawn != None)
            {
            x = xPawn(C.Pawn);
    		if(x != none && !x.bSkeletized)
    				{
    		x.LinkMesh(mesh(DynamicLoadObject("HumanMaleA.SkeletonMale",class'Mesh')), true);
     		x.bSkeletized = true;
    }
        if(C != none && C.PlayerReplicationInfo != none)
    	 switch(x.PlayerReplicationInfo.TeamID)
    	{
    case 0:
    		x.Skins[0]=ColorModifier'wm_textures.wm_ColorBars_Red';
    	break;
    case 1:
    		x.Skins[0]=ColorModifier'wm_textures.wm_ColorBars_Blue';
    	break;
    default:
    	Log("Unknown team, using default skin");
    		x.Skins[0]=Texture'PlayerSkins.Human_Skeleton';}
    	}
    }
    }
    
    defaultproperties
    {
         bOnlyDirtyReplication=False
         RemoteRole=ROLE_SimulatedProxy
         GroupName="Undead"
         FriendlyName="Undead Brawl"
         Description="Play as skeletons.|meheheheheheehheehhehe O_o"
         bAlwaysRelevant=True
         bSkipActorPropertyReplication=False
    }
    
     

Share This Page