• Do not use Works in Progress as a way of avoiding the releases system! Works in Progress can be used for sharing early betas and for getting suggestions for improvement. Releases of finished content are not allowed in this forum! If you would like to submit a finished addon, click here for instructions on how to do so.

Socs 2.1

Status
Not open for further replies.

M.V

Alright!
How do I do to edit my socs, because I don't have a number of things or states?

soc editor.png



I am not speaking about the version 2.0.7.

Code:
FRAME 1800
SPRITENUMBER = 11
SPRITESUBNUMBER = 1
DURATION = 1
NEXT = 1801
ACTION A_FindTarget
VAR1 = 222
VAR2 = 0
 
FRAME 1801
SPRITENUMBER = 11
SPRITESUBNUMBER = 1
DURATION = 5
NEXT = 1802
ACTION A_FindTarget
VAR1 = 222
VAR2 = 0
 
FRAME 1802
SPRITENUMBER = 11
SPRITESUBNUMBER = 1
DURATION = 10
NEXT = 1803
ACTION A_FireShot
VAR1 = 222
VAR2 = 0
 
FRAME 1803
SPRITENUMBER = 11
SPRITESUBNUMBER = 1
DURATION = 20
NEXT = 1804
ACTION A_FireShot
VAR1 = 222
VAR2 = 0
 
FRAME 1804
SPRITENUMBER = 11
SPRITESUBNUMBER = 1
DURATION = 15
NEXT = 1805
ACTION A_BunnyHop
VAR1 = 15
VAR2 = 15
 
FRAME 1805
SPRITENUMBER = 11
SPRITESUBNUMBER = 1
DURATION = 15
NEXT = 1800
ACTION A_FindTarget
VAR1 = 0
VAR2 = 0
 
SOCEdit does not work for 2.1. You need to write SOCs in a text editor yourself now.

You should reference Frames, Sprites, and Things directly now.

For example, if you were to modify Sonic's walking pose to spawn invincibility sparkles and for it to skip FRAME 5, you would do this in 2.0.7:

Code:
FRAME 4
ACTION A_SPAWNOBJECTRELATIVE
NEXT = 6
VAR2 = 164
However, in 2.1, you would reference everything by its name as shown below:

Code:
FRAME S_PLAY_RUN1
ACTION A_SPAWNOBJECTRELATIVE
NEXT = S_PLAY_RUN3
VAR2 = MT_IVSP
Likewise, if you were to increase the Egg Mobile's HP, you would do this in 2.0.7:

Code:
THING 29
SPAWNHEALTH = 16
And in 2.1, this is how you would increase the Egg Mobile's HP:

Code:
THING MT_EGGMOBILE
SPAWNHEALTH = 16
If you want to reference to a sprite, just do the same as you would with Frames and Things, except it would have a different prefix, obviously.

If you need to make new things, frames, or sprites, you must specify them in a FREESLOT category like so:

Code:
FREESLOT
MT_CUSTOMTHING
S_CUSTOMTHING_STAND
S_CUSTOMTHING_DASH1
S_CUSTOMTHING_DASH2
S_CUSTOMTHING_TOSS1
S_CUSTOMTHING_TOSS2
S_CUSTOMTHING_DODGE
S_CUSTOMTHING_DIE1
S_CUSTOMTHING_DIE2
SPR_CUSTOMTHING
Hopefully this helps you and other people out with 2.1's new SOC system.
 
Additionally, math can be performed in SOC fields, including many bitwise operations, most notably bitwise OR ( | ), which you'll use for adding flags together. A list of resource types and static names can be found in the first post of Monster's lua documentation thread.

Also of note, the SPR_ prefix can be omitted from the SpriteNumber field(now SpriteName), and the SpriteSubNumber field(now SpriteFrame) can use the frame letter, like A instead of 0 and E instead of 4.
 
Last edited:
Code:
FREESLOT
MT_CUSTOMTHING
S_CUSTOMTHING_STAND
S_CUSTOMTHING_DASH1
S_CUSTOMTHING_DASH2
S_CUSTOMTHING_TOSS1
S_CUSTOMTHING_TOSS2
S_CUSTOMTHING_DODGE
S_CUSTOMTHING_DIE1
S_CUSTOMTHING_DIE2
SPR_CUSTOMTHING

Do you want to be more specific?
 
Last edited:
Code:
FREESLOT
MT_CUSTOMTHING
S_CUSTOMTHING_STAND
S_CUSTOMTHING_DASH1
S_CUSTOMTHING_DASH2
S_CUSTOMTHING_TOSS1
S_CUSTOMTHING_TOSS2
S_CUSTOMTHING_DODGE
S_CUSTOMTHING_DIE1
S_CUSTOMTHING_DIE2
SPR_CUSTOMTHING

Do you want to be more specific?
Do you mean you want me to explain what that is?

Think of it as a table of contents listing for custom states, sprites, and things.
 
Do you mean you want me to explain what that is?

Think of it as a table of contents listing for custom states, sprites, and things.

I know what is. Can you give me an example of her filled out?

How do I leave with the number of " Thing 325 " for SRB2 Doom Builder?
 
Code:
FREESLOT
Object MT_MVBOSS
MAPTHINGNUM = 325
SPAWNSTATE = S_MVSTAND1
SPAWNHEALTH = 12
SEESTATE = 0
SEESOUND = 0
REACTIONTIME = 32
ATTACKSOUND = 0
PAINSTATE = 0
PAINCHANCE = 200
PAINSOUND = 0
MELEESTATE = 0 
MISSILESTATE = 0
DEATHSTATE = 0
DEATHSOUND = 0
XDEATHSTATE = 0
SPEED = 7
RADIUS = 1572864
HEIGHT = 2097152
MASS = 100
DAMAGE = 50 
ACTIVESOUND = 0
RAISESTATE = 0
FLAGS = MF_BOSS|MF_SHOOTABLE|MF_SPECIAL

Code:
FRAME S_MVSTAND1
SPRITENUMBER = SPR_SPOS
ACTION A_fIREsHOT
VAR1 = MT_ENERGYBALL
NEXT = S_MVSTAND1

Monday31stofMarch2014040602PM.png


I don't understand what there is wrong.
 
Last edited:
Actually the MT isn't needed after Object,It's more like this:


FREESLOT
MT_SOMETHING


Object SOMETHING
[insert code here]
 
With all the SOCs I've been making lately, I can vouch that it's not. You only need it in the declarations, not the Object SOMETHING part.
 
Code:
FREESLOT
MT_MVBOSS
 
Object MT_MVBOSS
MAPTHINGNUM = 325
SPAWNSTATE = S_MVSTAND1
SPAWNHEALTH = 12
SEESTATE = 0
SEESOUND = 0
REACTIONTIME = 32
ATTACKSOUND = 0
PAINSTATE = 0
PAINCHANCE = 200
PAINSOUND = 0
MELEESTATE = 0 
MISSILESTATE = 0
DEATHSTATE = 0
DEATHSOUND = 0
XDEATHSTATE = 0
SPEED = 7
RADIUS = 1572864
HEIGHT = 2097152
MASS = 100
DAMAGE = 50 
ACTIVESOUND = 0
RAISESTATE = 0
FLAGS = MF_BOSS|MF_SHOOTABLE|MF_SPECIAL

Code:
FRAME S_MVSTAND1
SPRITENUMBER = SPR_SPOS
ACTION A_FIRESHOT
VAR1 = MT_ENERGYBALL
NEXT = S_MVSTAND2
 
FRAME S_MVSTAND2
SPRITENUMBER = SPR_SPOS
ACTION A_FIRESHOT
VAR1 = MT_ENERGYBALL
NEXT = S_MVSTAND3
 
FRAME S_MVSTAND3
SPRITENUMBER = SPR_SPOS
ACTION A_FIRESHOT
NEXT = S_MVSTAND1

Is there something wrong? The object doesn't appear.
 
Last edited:
Your frames need to be in the Freeslot section too, so...

FREESLOT
MT_MVBOSS
S_MVSTAND1
S_MVSTAND2
S_MVSTAND3

Custom sprites and sounds also need to be here.
 
Okay, from my understanding, under FREESLOT you have to put stuff like this down (The comments are unnecessary, btw.):

Code:
FREESLOT
MT_NEOSPLATS
MT_GOLDCRAWLA
MT_EGGBOUNCER
MT_NEWSPIKE
[B]SPR_DAFT
SPR_PUNK
SPR_BOS1[/B]
S_PUNK_STND
S_PUNK_RUN1
S_PUNK_RUN2
S_PUNK_RUN3
S_PUNK_RUN4
S_PUNK_RUN5
S_PUNK_RUN6
S_NEWSPIKE
S_NEWSPIKE_FIND

Then for object definitions, type the same thing you set for your object, EXCLUDING the "MT_"

Code:
Object [B]GOLDCRAWLA[/B]
MapThingNum = 4013

Also, it appears you've forgotten SpriteFrame, and called SpriteName SpriteNumber in your states.

Code:
State S_PUNK_STND
Sprite[B]Name[/B] = PUNK
[B]SpriteFrame = A[/B]
Duration = 1
Next = S_PUNK_STND
Action = A_Look
Var1 = 0
Var2 = 0
 
Status
Not open for further replies.

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

Back
Top