Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - shadyman

Pages: 1 2 3 [4]
46
Dead Souls Support / Re: Running DS on fluffos
« on: October 02, 2007, 11:45:55 pm »
Ok, I got it up and running under FluffOS first try. It all seems to work, except as saquivor said, parsing items.

If I have two 9mil.c guns, load gun with clip works. wield gun does not. It gives:
Code: [Select]
2007.10.03-00.41
*Illegal to call parse_sentence() recursively.
Object: /secure/save/creators/s/shadyman (/lib/command.c) at line 529

'<fake>' at /secure/save/creators/s/shadyman (/<driver>) at line 0
'cmdAll' at /secure/save/creators/s/shadyman (/lib/command.c) at line 211
'parser_error_message' at /secure/daemon/master at line 1123
'eventRetryCommand' at /secure/save/creators/s/shadyman (/lib/command.c) at line 529

If I go into Otik's storage room (/domains/town/room/shop2), I can:
"take shirts":
Code: [Select]
> take shirts
You get a sturdy-looking chainmail shirt.
You get a sturdy-looking chainmail shirt.

But I can't take flask
Code: [Select]
You can't get ye flask.Sorry, Homestar Runner joke.
Trying to 'take flask' gives the same error as wielding gun.

I'll see if I can hunt it down.

47
Dead Souls Support / Re: Running DS on fluffos
« on: October 01, 2007, 10:05:54 pm »
What should the heartbeat be? 1000?

48
Code Vault / HideExit code
« on: January 13, 2007, 05:01:19 pm »
This is my update to the /lib/exits.c and /lib/std/room.c to make obvious exits easier to use and worth with. It adds the following:

    * a sub-mapping to the Exits mapping in exits.c to include ([ "obv" : 0 or 1 ]).
    * HideExit(dir), which hides the given exit (and should be used in your room code to hide exits)
    * GetObvMap(), which returns a mapping of direction and hidden [Example where south is hidden by HideExit("south"): ([ "west" : 1, "north" : 1, "east" : 1, "south" : 0 ]) ].

Room Exits default to Obvious, so there is no need to set them. The old SetObviousExits and its related functions are still included and valid for compatibility purposes. I will be releasing another version of this code for use with muds who want more than the [n, s, e, w, u] exit list.

Update: Moved one block of code in GenerateVerboseExits() in room.c to allow you to HideExit() enters. (Example: HideExit("enter office"); )

Click Here to go to my site to download

49
Code Vault / Re: Verbose Exits in 2.3a1
« on: January 13, 2007, 04:54:41 pm »
This is my update to the /lib/exits.c, /lib/std/room.c and /lib/interactive.c to allow for worded exits in verbose mode, and the usual short exits in brief mode. Examples:

    * Verbose:
          o Creators' Hall
          o Immortals come here to communicate with each other about the world they are building. The Adventurer's Guild is north. The Arch Room is south. To visit the Dead Souls test and development mud, go west. The test lab facilities are east.
          o There are five obvious exits: west, north, east, south, and up.
    * Brief:
          o Creators' Hall [n, s, e, w, u]

This code includes my HideExit Modifications.  Disclaimer: Your doors should have shorts like "door leading south" instead of "a door leading south"

Update: Moved one block of code in GenerateVerboseExits() in room.c to allow you to HideExit() enters. (Example: HideExit("enter office"); )

50
Code Vault / Verbose Exits in 2.3a1
« on: January 13, 2007, 12:00:57 am »
Check my website:

http://erroraccessdenied.com/node/860

Description and download are on that page  ;D

51
2006 Contest / Contest Announcement
« on: October 07, 2006, 10:16:02 pm »
Yay contests!  B-)

52
Dead Souls Support / Ubuntu 6.06
« on: October 18, 2006, 07:38:46 pm »
And don't forget to



code:
sudo apt-get install build-essential




first

 :O)

53
Dead Souls Support / Fix for channel emotes
« on: September 14, 2006, 03:26:52 pm »

Ace!  B-)



Good eyes. I figured it was something I had done until i got on Dead Souls Demo and managed the same bug.  (nod)


54
Dead Souls Support / DS 2.2 to do list
« on: September 12, 2006, 09:18:36 pm »
So long as none of that is supposed to make sense to anyone other than you  :O)
--Shady@QS

55
General / doors in interactive.c, help please
« on: October 20, 2006, 09:18:02 pm »
This guy has to go in your /lib/exits.c  :>



code:

int GetExitObv( string str ) {
    if( !Exits[str] ) return 0;
    else return Exits[str]["obv"];
}

56
General / doors in interactive.c, help please
« on: October 19, 2006, 09:19:49 pm »

Oooh. Good point.



I had to hack it in from the previous (read: old) version of DS, when doors/exits were really rather different. I was sure I didn't catch everything, and that would be it. Good eye (nod)



I'll post a new version here when it's done.


57
General / doors in interactive.c, help please
« on: October 18, 2006, 07:24:11 pm »
Here's how I did mine. It's a little different, but then again, display design styles are different :)



I added "GenerateVerboseExits()" to my room.c, incase I ever wanted to get this string from somewhere else (ie, interactive.c, etc)



Code: room.c

code:
string GenerateVerboseExits(){
    string *normals;
    int exitCount = 0;
    string *roomexits;
    string *entersArray;
    string dir_string, enters;
    string temp,temp2;
    roomexits = GetExits();

   foreach( string ex in roomexits )
   {
      if( LIB_EXITS->GetExitObv( ex ) ) {
          roomexits -= ({ex});
       }
   }

    enters = "";
    normals = ({ "north", "south", "east", "west", "up", "down" });
    normals += ({ "northeast", "southeast", "northwest", "southwest" });
    normals += ({ "out" });
    dir_string = "";

    if( sizeof(GetEnters(1)-({0})))
    {
        entersArray = this_object()->GetEnters(1);
        foreach( string en in entersArray )
        {
           entersArray[exitCount++] = "enter "+entersArray[exitCount];
        }
        roomexits += entersArray;
    }

    exitCount = 0;
    if( sizeof( roomexits ) == 0 )
       dir_string += "%^BOLD%^WHITE%^There are no obvious exits%^RESET%^. ";
   else if( sizeof(roomexits) == 1 )
        dir_string += "%^BOLD%^WHITE%^There is "+ cardinal((int)sizeof(roomexits)) +" obvious exit%^RESET%^: ";
    else
       dir_string += "%^BOLD%^WHITE%^There are "+ cardinal((int)sizeof(roomexits)) +" obvious exits: ";

   //Generate Brief list
   //Brief = implode(roomexits,", ");

    foreach( string ex in roomexits )
    {
       //Generate Verbose list
       if (GetDoor(ex)) {
          temp = find_object(GetDoor(ex))->GetClosed();
          temp2 = find_object(GetDoor(ex))->GetShort();
         if (temp) {
            dir_string += "a closed "+temp2+" to the %^RED%^"+roomexits[exitCount]+"%^RESET%^";
         } else {
             dir_string += "an open "+temp2+" to the %^BOLD%^GREEN%^"+roomexits[exitCount]+"%^RESET%^";
          }
       } else {
           dir_string += "%^BOLD%^GREEN%^"+roomexits[exitCount]+"%^RESET%^";
        }

        if( ++exitCount == (sizeof( roomexits )-1) ) dir_string += ", and ";
        else dir_string += ", ";
    }

    if(last(dir_string,2) == ", ") dir_string = truncate(dir_string,2);
    dir_string = replace_string(dir_string,", , ",", ") + ".";
    return dir_string;
}






My Interactive.c, starting at like 2somethingsomething.. (If (!brief))

code:
    if( !brief ) {
      if( i == VISION_CLEAR ) {
          desc = capitalize("%^BOLD%^WHITE%^" + (string)env->GetShort() + "%^RESET%^\n" || "");
          //+ " [" + desc + "]\n";
      } else desc = "";

      if( i == VISION_CLEAR || i == VISION_LIGHT || i == VISION_DIM )
          desc += (string)env->GetLong()+"\n";

      desc += (string)env->GenerateVerboseExits() || "";

      if(functionp(tmp = (mixed)env->GetSmell("default")))
          tmp = (string)(*tmp)("default");
      smell = tmp;
      if(functionp(tmp = (mixed)env->GetListen("default")))
          tmp = (string)(*tmp)("default");
      sound = tmp;
      if( functionp(tmp = (mixed)env->GetTouch("default")) )
          tmp = evaluate(tmp, "default");
      touch = tmp;
    }




As you can see, I nerfed the [n,s,e,w] from up top by the title because we get a nice, verbose message instead. If folks want it brief, they can see [n,s,e,w].



I think that's all the code that it needs, but maybe not.  (devil)





Edit:

Disclaimer: Doors must have a short like "metal door" or "iron gate", etc to display correctly.

Pages: 1 2 3 [4]