#pragma strict_types
inherit "/std/object";
inherit "/lib/keep";
string dlugosc;
string typ;
string opis;
string *subloki;
#include "dir.h"
#define SUBLOC "fryzura_na_glowie"
void
create_object()
{
set_keep(1);
ustaw_nazwe( ({ "fryzura", "fryzury", "fryzurze", "fryzure",
                 "fryzura", "fryzurze" }), ({ "fryzury", "fryzur", "fryzurom", "fryzury",
                 "fryzurami", "fryzurach" }), PL_ZENSKI);
ustaw_shorty( ({ "fryzura", "fryzury", "fryzurze", "fryzure",
                 "fryzura", "fryzurze" }), PL_ZENSKI);
    add_prop(OBJ_M_NO_DROP, 1);
    add_prop(OBJ_M_NO_STEAL,1);
    add_prop(OBJ_M_NO_SELL, 1);
    add_prop(OBJ_M_NO_GIVE, 1);
    add_prop(OBJ_I_WEIGHT, 0);
    add_prop(OBJ_I_VOLUME, 0);
    add_prop(OBJ_I_VALUE, 0);
set_no_show();
this_player()->add_subloc(SUBLOC, this_object());
}
string
show_subloc(string subloc, object carrier, object for_obj)
{
    string str;
    if (carrier->query_prop(TEMP_SUBLOC_SHOW_ONLY_THINGS))
        return ""; /* Don't show this sublocation as inventory. */
    if (for_obj == carrier)
        str = "Twoje ";
    else
        str = this_player()->koncowka("Jego ","Jej ");
    return str +  dlugosc + ", " + typ + " wlosy " + opis + ".\n";
}
public string
query_auto_load()
{
    return (MASTER + ":" + dlugosc + "," + typ + "," + opis);
}
public void
init_arg(string arg)
{
int pom = 0;
int i;
    string s1, s2, s3;
    if (sscanf(arg, "%s,%s,%s", s1, s2, s3) == 3)
    {
        dlugosc = s1;
        typ = s2;
        opis = s3;
    }
subloki = this_player()->query_sublocs();
for (i =0;i<sizeof(subloki);i++)
if (subloki[i] == SUBLOC)
    pom = 1;
if (!pom) this_player()->add_subloc(SUBLOC, this_object());
}
string
cz_opis()
{
return opis;
}
string
cz_dlugosc()
{
return dlugosc;
}
string
cz_typ()
{
return typ;
}
void
s_typ(string str)
{
typ = str;
}
void
s_dlugosc(string str)
{
dlugosc = str;
}
void
s_opis(string str)
{
opis = str;
}
void
init()
{
    add_action("fry_pom", "frpomoc");
    add_action("fry_pop", "frpopraw");
    add_action("fry_rwi", "frrwij");
    ::init();
}
int
fry_rwi()
{
write("Rwiesz wlosy z glowy w niemym gescie rozpaczy.\n");
saybb(QCIMIE(this_player(), PL_MIA) + " rwie wlosy z glowy" +
    " w niemym gescie rozpaczy.\n");
return 1;
}
int
fry_pop()
{
write("Poprawiasz od niechcenia swoja fryzure.\n");
saybb(QCIMIE(this_player(), PL_MIA) + " poprawia od niechcenia" +
    " swoja fryzure.\n");
return 1;
}
int
fry_pom()
{
write("Dostepna lista komend zwiazana z fryzura:\n\n");
write("frpopraw - poprawiasz swoja fryzure\n");
write("frrwij - rwiesz wlosy z glowy w gescie rozpaczy\n\n");
write("frpomoc - widoczny spis komend.\n");
return 1;
}