mirror of
https://github.com/Facepunch/sbox-public.git
synced 2026-01-02 11:28:19 -05:00
This commit imports the C# engine code and game files, excluding C++ source code. [Source-Commit: ceb3d758046e50faa6258bc3b658a30c97743268]
52 lines
1.2 KiB
Modula-2
52 lines
1.2 KiB
Modula-2
|
|
#include "sbox/resourcehandles.h"
|
|
|
|
[ResourceHandle:HMaterial]
|
|
native class IMaterial2 as NativeEngine.IMaterial
|
|
{
|
|
string GetName();
|
|
string GetNameWithMod();
|
|
|
|
ulong GetSimilarityKey();
|
|
|
|
bool IsLoaded();
|
|
|
|
IMaterialMode GetMode( StringToken token );
|
|
IMaterialMode GetMode();
|
|
|
|
inline IMaterialMode GetMode( ISceneLayer layer )
|
|
{
|
|
return self->GetMode( layer->GetShaderMode() );
|
|
}
|
|
|
|
CRenderAttributes GetRenderAttributes();
|
|
|
|
void RecreateAllStaticConstantAndCommandBuffers();
|
|
|
|
ITexture GetFirstTextureAttribute();
|
|
|
|
bool GetBoolAttributeOrDefault( StringToken name, bool i );
|
|
int GetIntAttributeOrDefault( StringToken name, int i );
|
|
float GetFloatAttributeOrDefault( StringToken name, float f );
|
|
ITexture GetTextureAttributeOrDefault( StringToken name );
|
|
|
|
bool HasParam( string name );
|
|
|
|
void Set( string name, string val );
|
|
string GetString( string name, string defaultValue );
|
|
|
|
void Set( string name, Vector4 value );
|
|
Vector4 GetVector4( string name );
|
|
|
|
void Set( string name, ITexture value );
|
|
ITexture GetTexture( string name );
|
|
|
|
void SetEdited( bool b );
|
|
bool IsEdited();
|
|
|
|
inline void ReloadStaticCombos()
|
|
{
|
|
self->ReloadStaticCombos( *((HMaterialStrong *)__self) );
|
|
}
|
|
}
|