Hey everyone,

As my only contribution for the HPL2 modding community, I'm porting the Labs assets from SOMA to Amnesia. It's a nice assets pack and it's not that hard to use (compared to other assets from SOMA).



What does the pack include:

  1. Lab static objects (walls, welders, ceiling, etc)
  2. Some lamps
  3. Some chairs
  4. Working slidedoors

make sure to report any bugs if you find any.

If anyone wants to help me with porting/fixing bugs, it will be very appreciated!

VERSION 1.0.0 - CHANGELOG:

  • Slidedoor script update

VERSION 0.9.0 - CHANGELOG:

  • Added broken slidedoors
  • Fixed some materials

VERSION 0.8.5 - CHANGELOG:

  • First release

What's still needed to be done:

  1. Add more lamp versions with different colors
  2. Port more furniture
  3. Port some sounds
  4. Add crush death script for the slidedoors (if possible)

I'll probably continue it when I'm bored.

RSS Articles

Slidedoor setup tutorial (With pictures)

Mapping/Technical Tutorial

Hi there,

If you want to use the SOMA slidedoor in amnesia, you need to setup some stuff in the map itself and the map's script file. Let's see what we need to do.


1. Setup the door's name and the panels - every slidedoor should have a specific name, and this name is determined by the string "Slidedoor" + the first panel's name that is connected to the door:

The first panel's name

The first Panel's name



Therefore, our slidedoor's full name will be: "Slidedoor_panel_1_1".

Slidedoor

The slidedoor's full name



As for the second panel, which will be at the other side of the door, will be called "panel_1_2".

*Note: if we wanted to add another door to the map, the first door's panels will be called "panel_2_1, the second will be called "panel_2_2" and the slidedoor will be called "Slidedoor_panel_2_1" and so forth.

This is very important to name the doors like that, or else it won't work!


2. Setup the slidedoor's buttons - Naming the buttons isn't enough! We need to also add a ConnectionStateChangeCallback to make the door open/close when the button is turned on/off.

Under the panel's entity tab, paste this callback name in the ConnectionStateChangeCallback bar:

slidedoor_OnChangeState

state


Now, every time the button is pressed, this function will be called and will open/close the door. Make sure to implement that callback function in both panels.

Now we're ready to do the final step.


3. Setup the slidedoor script - In order to make the magic work, we need to tie everything together in the map's script file. The basic script is as the following (This script can be found in the example map included with the pack):

//PROPERTIES//
string sOppositeButton;
string sCurrentSlideDoor;
bool mbDoorIsClosing = false;

//----------------------------------------------------

void slidedoor_OnChangeState(string& entity, int alState)
{
	if(alState == 1)
	{
		PlaySoundAtEntity("Open", "theta_button_door_open_01.snt", entity, 0, false);
		slidedoor_HandleButtonDetection(entity);
		SetMoveObjectState("Slidedoor_"+entity, 1);
		SetButtonSwitchedOn(sOppositeButton, true, true);
		
		sCurrentSlideDoor = "Slidedoor_"+entity;
		PlaySoundAtEntity("DoorOpen", "theta_slidedoor_open.snt", sCurrentSlideDoor, 0, false);
		
		mbDoorIsClosing = false;
		AddDebugMessage("Door is opening", true);
	}
	
	else
	{
		PlaySoundAtEntity("Close", "theta_button_door_close_01.snt", entity, 0, false);
		slidedoor_HandleButtonDetection(entity);
		SetMoveObjectState("Slidedoor_"+entity, 0);
		SetButtonSwitchedOn(sOppositeButton, false, true);
		
		sCurrentSlideDoor = "Slidedoor_"+entity;
		PlaySoundAtEntity("DoorClose", "theta_slidedoor_close.snt", sCurrentSlideDoor, 0, false);
		
		mbDoorIsClosing = true;
		AddDebugMessage("Door is closing", true);
	}
}

//----------------------------------------------------

void slidedoor_HandleButtonDetection(string& entity)
{
	if(StringSub(entity, 7, 2) == "_1") sOppositeButton = StringSub(entity, 0, 7) +"_2";
	else if(StringSub(entity, 7, 2) == "_2") sOppositeButton = StringSub(entity, 0, 7) +"_1";
}

//----------------------------------------------------

void OnStart()
{
	PreloadSound("theta_button_door_open_01.snt");
	PreloadSound("theta_button_door_close_01.snt");
	PreloadSound("theta_slidedoor_open.snt");
	PreloadSound("theta_slidedoor_close.snt");
}

//----------------------------------------------------


void OnEnter(){ }

void OnLeave(){ }

void OnGameStart(){ }

Just copy that and use it as your base script file for your map.

Note: This is not the final version of the script, it may be changed as updates will come.


Now, if you've done everything right, the door should open and close!

Screen Screenshot 000

Add file RSS Files
Lab Assets Pack [Version 1.0.0]

Lab Assets Pack [Version 1.0.0]

Models Pack 3 comments

The assets pack + an example map. Will be updated in the future. Report any bug/problem!

Comments  (0 - 10 of 15)
OrganicShelter
OrganicShelter

What does the 1.0.0 update do?

Reply Good karma Bad karma+1 vote
TiManGames Creator
TiManGames

You can see the changes in the changelog.

Reply Good karma+1 vote
umukzus
umukzus

Looks fantastic,

honestly though... HPL3 is such a pain to edit...

Reply Good karma Bad karma+1 vote
TiManGames Creator
TiManGames

I think it's pretty straightforward.

Reply Good karma+1 vote
EvanIsGolden
EvanIsGolden

this will be perfect for my custom story called The Factory! as soon as i saw this my mouth drooped and i was amazed to death!

Reply Good karma Bad karma+1 vote
OrganicShelter
OrganicShelter

Would be good if you import the fleshy black substance thing too

Reply Good karma Bad karma+1 vote
OrganicShelter
OrganicShelter

I mean the WAU

Reply Good karma Bad karma+1 vote
KiraImmortal
KiraImmortal

this actually looks like a nice addition! i might implement it into something one day :) and about the monsters, i also wasn't able to solve the issue for the others.

Reply Good karma Bad karma+3 votes
TheGamerPro9071
TheGamerPro9071

Yes, is possible, KiraImortal do in his mod Black eagle tavern tales, but in his oldest version in the new one is not, and only put one monster.

Reply Good karma Bad karma+3 votes
TiManGames Creator
TiManGames

He only managed to port the Flesher because this was the only model that didn't have animation bugs. All the other models have their animations screwed up if you port them to hpl2.

Reply Good karma+1 vote
Post a comment
Sign in or join with:

Only registered members can share their thoughts. So come on! Join the community today (totally free - or sign in with your social account on the right) and join in the conversation.

Follow Report Profile
Icon
Amnesia: The Dark Descent
Creator
Contact
Send Message
Release date
Mod watch
Follow
Share
Community Rating

Average

10

1 vote submitted.

You Say

-

Ratings closed.

Style
Genre
Adventure
Theme
Sci-Fi
Players
Single Player
Twitter

Latest tweets from @frictionalgames

It's so-o #TotallyDigital! Our titles are 66% OFF for the next month in PlayStation Stores of Europe, Africa, Middl… T.co

16hours ago

We're at #TheGameAssembly Meet and Greet in #Malmö's Moriska Paviljongen! Come say hi, and pick up our cool flyer t… T.co

Apr 25 2018

If you're still not convinced to buy SOMA, you can read some good, good words @pcgamer wrote about our ladders.… T.co

Apr 23 2018

25th of April is St. Catherine's Day - let her namesake bless you with Frictional's Saint Sale on Steam, running 20… T.co

Apr 20 2018

We are celebrating the first ever sale event of SOMA on #XboxOne! 🎉 The game will be 40% off during 17th to 23rd of… T.co

Apr 17 2018

Some people want the authentic horror experience, others prefer a stress-free story experience. @NotFunnyJ from… T.co

Apr 13 2018

Here's one fan's list of the 10 most terrifying enemies we've ever made! Do you agree? Which one of our monsters k… T.co

Apr 9 2018

The number one kat-alyst of stress at Frictional is @LosFreddos and @katvesi's love of puns. Are we fired... or are… T.co

Apr 6 2018

RT @gamecovevocemag: Penumbra: Overture - Episode 1 Mobygames.com T.co

Apr 5 2018

RT @gamecovevocemag: Penumbra: Overture - Episode 1 Mobygames.com T.co

Apr 5 2018

Embed Buttons
Link to SOMA Lab Assets Pack for Amnesia by selecting a button and using the embed code provided more...
SOMA Lab Assets Pack for Amnesia
Statistics
Last Update
Watchers
4 members
Addons
1
Articles
1
Reviews
1