Diferent Objects with same Frames

Status
Not open for further replies.

Kratzean

Member
Hi, I want to make different objects in SRB2, for example enemies and scenery.

My problem is, that some of the enemies and scenery objects have similar frames, but only with other sprites, so that I want to ask for a way to use the same frames but with other sprites for the object.

How I can do this? Perhaps with a lua script or other?
 
Look at this

(Taken from SRB2 wiki)
Attributes

Every state has several attributes assigned to it. They include the sprite that the Object should display while in the state, an action to perform, the duration of the state and the next state to call. The action is optional, but all other attributes are mandatory.
SpriteName: The four-letter prefix for the sprite set to use while in the current state. Every Object (except for invisible ones and cases where multiple Objects share the same sprites) has its own sprite set which contains all sprites that it may display. This parameter does not actually choose the sprites, it only specifies in which set they can be found. A complete listing of sprite sets can be found in the list of sprites.
SpriteFrame: Out of the selected sprite set, this chooses which frame to display. A frame is a single freeze image of an Object, displayed from up to eight different angles. The value to be used is the fifth letter of the desired sprite's lump name, e.g. "A" if the sprite's name is PLAYA1. Additionally, certain values can be added on top of that to specify the frame's transparency and brightness settings. The bitwise OR operator (|) should be performed on these values to combine them, e.g. FF_FULLBRIGHT|TR_TRANS10|A.
FF_FULLBRIGHT: full brightness, the sprite is not affected by lighting
TR_TRANS10: 10% transparent (90% opaque)
TR_TRANS20: 20% transparent (80% opaque)
TR_TRANS30: 30% transparent (70% opaque)
TR_TRANS40: 40% transparent (60% opaque)
TR_TRANS50: 50% transparent (50% opaque)
TR_TRANS60: 60% transparent (40% opaque)
TR_TRANS70: 70% transparent (30% opaque)
TR_TRANS80: 80% transparent (20% opaque)
TR_TRANS90: 90% transparent (10% opaque)
Duration: This sets how long the state lasts in tics (35 tics equal one second). Set it to 0 to instantly change to the next state, and to -1 to make the state last indefinitely. Note that an Object's SpawnState may not have a duration of 0.
Action: Specifies an action to be performed during the state. This parameter is optional; not all states need to include an action.
Var1 and Var2: These are variables that can modify the behavior of some actions. Their purpose depends on the action being used and is documented in the Wiki article for the respective action.
Next: Specifies the state to go to after the current state's duration is over.
SOC definition /
 
You don't understand me! I want to make, that similar objects can have the same frames (because some objects have similar actions), but different sprites for the objects!!!
 
Not possible, from my knowledge. You have to copy, paste, and then give it a new name and different sprite.
 
I know this way (but thx for the information).

But I think, that its a good idea, if we can use frames for different objects, because so we don't need more frames from the free slots...
 
Status
Not open for further replies.

Who is viewing this thread (Total: 1, Members: 0, Guests: 1)

Back
Top