Manual:Zone Manual/The NPC Section/Dragon station with rooms and NPCs

From DikuMUD Wiki
< Manual:Zone Manual‎ | The NPC Section
Revision as of 14:21, 25 May 2020 by Nove (talk | contribs) (Created page with "=== Dragon station with rooms and NPCs === Now we will add the NPCs we have built to the zone from the previous chapter. This is still not complete while it does compile a...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Dragon station with rooms and NPCs

Now we will add the NPCs we have built to the zone from the previous chapter. This is still not complete while it does compile and you can log into your zone, you still have to load your NPCs and there are no objects. These will be added as you progress through this manual. The following is the source file so far.

	#include <composed.h>
	%zone dragonst
	lifespan 20
	reset RESET_ANYHOW
	creators {"whistler"}

	notes
	"This is the dragon station I shortened it to dragonst for ease in
	loading.  If you have  any questions email me at whistler@valhalla.com"

	help
	"Not sure what could help you now.  You are stuck on one of the
	weirdest space stations you have ever seen and you smell burning
	sulfur."

	%rooms

	chamber
	title "The middle chamber of the station"
	descr
	"This chamber seems to have the entire station rotating around it.  It is
	unbelievably large the ceiling seems to be a good 200 meeters high and
	the room is perfectly cubic. Small human size ornate chairs with dragon
	designs scrawled on the arms and back are arranged in a triangle like
	setting with one large chair at the front.  This must be where all
	station meetings are held. large pictures cover the walls depicting
	dragons in all kinds of situations.  large passages lead of to the west
	and the east.."

	extra {"chair","chairs"}
	"The chairs are made of some metal you don't recognize and every inch is covered
	with some kind of dragon."

	extra  {"dragon picture","picture"}
	"Thousands of dragons dot the skies of this rather life like picture.  In the
	center you see something move.  It looks to be a little green dragon."

	extra{"green dragon","dragon","green"}
	"An intellegence looking dragon is sitting perched on a large chair watching you."

	movement SECT_INSIDE
	ALWAYS_LIGHT
	flags {UNIT_FL_NO_WEATHER, UNIT_FL_INDOORS}

	west to disposal_room descr
	"You see a small room.";

	east to hallway descr
	"You see what looks to be a hallway.";

	end

	hallway
	title "Module tunnel"
	descr "The hallway is about 50 meters long and around 100 meters from
	side to side and top to bottom.  The hallway seems to be dust free.  The
	walls and the floors seem to be made out of the same sterile
	metal-plastic that all space agencies uses.  There are large plate glass
	windows that open up into space.  The hallway is filled with a dim light
	that seems to come from everywhere yet no where all at once.  You notice
	a glimmer of bright light coming from the windows.  To the east you see
	an air lock and to the west the hallway opens up into a larger room."

	extra {"windows","window"}
	"Your eyes are drawn to a large ship lit up with running lights sitting
	about 1 kilometer from the station."

	extra{"floor","walls","wall"}
	"Well what can be said it looks to be in perfect condition.  What else would
	you want to know?"

	extra {"large ship" ,"ship"}
	"The ship looks really big and is shaped like a dragon.  The scales
	sparkle and seem to be multiple colors."

	movement SECT_INSIDE
	ALWAYS_LIGHT
	flags {UNIT_FL_NO_WEATHER, UNIT_FL_INDOORS}

	west to chamber descr
	"The hallway opens up into a chamber.";

	east to office descr
	"You see what looks to be an office."
	keyword {"air lock door","air lock","door"}
	open {EX_OPEN_CLOSE, EX_CLOSED};

	end

	office
	title "The station office"
	descr
	"Large paintings fill the walls of this part of the station.  The room
	is as large as the other rooms big enough for Dragons to lounge while
	still having a desk in one corner small enough for a humanoid.  The
	floor along the north wall is lined with some kind of fabric and seems
	very soft to walk on, it may be some kind of dragon lounge judging by
	how large an area it covers.  There is a passage to the west."

	movement SECT_INSIDE
	ALWAYS_LIGHT
	flags {UNIT_FL_NO_WEATHER, UNIT_FL_INDOORS}

	extra {"paintings","painting"}
	"The paintings are of many dragons and riders in all kinds of tasks from
	combat to look out.  All the figures seem to be staring at a staff
	being held by a depiction of a wizard on the south wall."

	extra {"wizard","staff"}
	"The wizard has his hand stretched out and it seems there is a place
	you can almost grab the staff. Maybe if you searched the staff you would
	find it."

	extra {"desk"}
	"Its a desk alright but there doesn't seem to be any drawers and it
	seems totally empty."

	extra{"fabric"}
	"Wussshhhhh you bound across the comfortable floor wasn't that fun."

	west to hallway descr
	"You see what looks to be a hallway."
	keyword {"air lock door","air lock","door"}
	open {EX_OPEN_CLOSE, EX_CLOSED};

	SECRET_DOOR_DIFFICULTY(SOUTH, 50)
	south to portal_room descr
	"You see what looks to be a portal room."
	keyword {"air lock door","air lock","staff","door"}
	key nokey
	open {EX_OPEN_CLOSE, EX_CLOSED,EX_LOCKED,EX_HIDDEN};

	end

		portal_room
		title "Green field room"
		descr
		"Like the other rooms on the station this one is large enough for
		dragons to comfortably fit in.  The strange thing about this room though
		is it is totally empty except for a green field right in the center.
		there is a door that leads to another room to the north."

		movement SECT_INSIDE
		ALWAYS_LIGHT
		flags {UNIT_FL_NO_WEATHER, UNIT_FL_INDOORS}

		extra {"green field","field"}
		"The field looks to be a green fog shifting and churning as you watch.
		if you are nuts you could probably enter it."

		north  to office descr
		"You see what looks to be an office."
		keyword {"air lock door","air lock","door"}
		key nokey
		open {EX_OPEN_CLOSE, EX_CLOSED,EX_LOCKED};

		//A link to the portal is also here from room_port
		end

		ship_port
		names{"green field", "field"}
		title "Green field"
		descr
		"Green Mist swirls about you."

		movement SECT_INSIDE
		ALWAYS_LIGHT
		flags {UNIT_FL_NO_WEATHER, UNIT_FL_INDOORS}

		in ship

		dilcopy force_move@function(
		//Time to activation
		4,
		//room and act
		"portal_room@dragonst!You feel your body dissolving for lack of a better
		description.&nYou appear on the deck of a ship.",
		//True or False for randomizing or not
		FALSE);

		end

	room_port
	names{"green field", "field"}
	title "Green field"
	descr
	"Green Mist swirls about you."
	movement SECT_INSIDE
	ALWAYS_LIGHT
	flags {UNIT_FL_NO_WEATHER, UNIT_FL_INDOORS}

	in portal_room

	dilcopy force_move@function(
	//Time to activation
	4,
	//room and act
	"ship@dragonst!You feel your body dissolving for lack of a better
	description.&nYou appear on the deck of a ship.",
	//True or False for randomizing or not
	FALSE);

	end

	disposal_room
	title "Red field room"
	descr
	"Like the other rooms on the station this one is large enough for
	dragons to comfortably fit in.  The strange thing about this room though
	is it is totally empty except for a red field right in the center.
	there is a door that leads to another room to the east."

	movement SECT_INSIDE
	ALWAYS_LIGHT
	flags {UNIT_FL_NO_WEATHER, UNIT_FL_INDOORS}

	extra {"red field","field"}
	"The field looks to be a red fog shifting and churning as you watch.
	if you are nuts you could probably enter it."

	east to chamber descr
	"You see the main chamber.";

		//A link to the portal is also here from dis_port
	end

	dis_port
	names {"red field","field"}
	title "Red field"
	descr
	"Red Mist swirls about you."

	movement SECT_INSIDE
	ALWAYS_LIGHT
	flags {UNIT_FL_NO_WEATHER, UNIT_FL_INDOORS}
	dilcopy force_move@function(
	//how fast to force move in seconds
	4,
	//room to force move to and act
	"deathspace@dragonst!You feel your body dissolving for lack of a better description.",
	//true or false random move or not
	0);
	in disposal_room

	end

	ship
	title "War dragon"
	descr
	"Blue light softly glows from con duets that line the walls of this ship.
	The floors beside the east and west wall have what looks to be soft
	fabric covering.  The south wall has small controls that seem to be made
	for humanoids with two small chairs that look to be pilot seats.  view
	portals are about 50 meters up the side of the ship on the west and east
	wall and some kind of electronic screen covers the south wall.  The ship
	seems to be a one room ship but there is a green field by the north
	wall."

	movement SECT_INSIDE
	ALWAYS_LIGHT
	flags {UNIT_FL_NO_WEATHER, UNIT_FL_INDOORS}

	extra {"view port"}
	"Sorry your not 50 meters tall maybe it is made for a dragon?"

	extra {"view screen","screen"}
	"It seems to be the pilots view screen but you can't seem to see a way
	to turn it on."

	extra {"controls","control"}
	"The controls are in some weird language and your afraid if you start
	pushing buttons you might rocket in to the station or worse slam into
	a planet."

	extra {"soft fabric","fabric"}
	"It looks to be a dragon lounge area."

		//A link to the portal is also here from ship_port
	end

	deathspace
	title"Open space"
	descr
	"You see the ship and the station far off in the distance and you are in Space!"

	movement SECT_INSIDE
	ALWAYS_LIGHT
	flags {UNIT_FL_NO_WEATHER, UNIT_FL_INDOORS}

	dilcopy death_room@function (
	//how often is damage done 4 would be 1 second
	4,
	//damage
	400,
	//act for the damage.
	"You realize to late that was the trash disposal transporter and you feel your
	lungs explode.");

	end

	%mobiles

	bldragon

	title "a black dragon"
	descr "A big ugly black dragon is clawing the ground here."
	names {"big ugly black dragon","ugly black dragon","big black dragon",
	"black dragon","dragon"}

	extra {}
	"The black dragons scales glitter like black granite that has been
	polished for years by water.  He has a large neck and huge bat like
	wings.  his eyes watch you as you stand before him.  One claw seems to be
	tapping slightly on the ground as if the dragon is waiting for
	something."

	extra {"eye","eyes"}
	"The dragons eyes seem to follow you no matter where you go in the room
	nothing seems to escape the dragons attention."

	extra {"claws","claw"}
	"The claw is big black and it looks very deadly.  It seems like the
	dragon has two sets of 4 large claws and 2 sets of 4 smaller claws which
	to say means the claws are about the size of short swords and long
	swords."

	extra {"scales","scale"}
	"Its a scale!  Haven't you ever seen a dragon before!"

	extra {"bat wings","wings"}
	"The dragon sees you looking and flaps his wings creating one heck of a
	wind blast."

	M_DRAGON_BLACK_OLD(SEX_MALE)

	end

	janitor
	names {"ugly janitor", "janitor", "hobgoblin"}
	title "an ugly janitor"
	descr "an ugly janitor is walking around, cleaning up."

	extra{}
	"This ugly green thing looks more goblin than hobgoblin but he seems intent
	on cleaning everything around him."

	M_AVG_HOBGOBLIN(6, SEX_MALE)

	// he is sort of good for cleaning so much
	alignment 900

	//give him some money
	money 5 IRON_PIECE

	dilcopy janitors@function(15);

	// only want him cleaning the station
	dilcopy wander_zones@function("dragonst", 20, 1, 1);

	end

	bob

	names {"Bob"}
	title "Bob"
	descr "Bob the Banker is here, sitting behind the counter."
	extra {}
	"He has a very serious look on his face."

	// define from composed.h
	M_SHOP_KEEPER(4, SEX_MALE, RACE_HUMAN)

	//discourage people from killing banker
	exp -500

	flags {UNIT_FL_NO_TELEPORT}

	special SFUN_BANK
	end

	%end