Author Topic: Npc Dialogue on login.  (Read 128 times)

Offline AdotSells

  • Firecape Member
  • *
  • Posts: 300
  • Rep 4
    • View Profile
Npc Dialogue on login.
« on: March 29, 2011, 01:16:01 am »
Difficulty 2/10
Base; Delta cleaned
Knowledge needed; C&p
How hard is it; Easy

This is for my Delta cleaned souce.

This will all be done in client.java

Find you'r Login message . In my case it'll be
Quote
sM("Welcome to RuneWorld");

Above that Add this

Quote
talk1("#TEXT#"0);

Soo compile And test . you should have 1 line of text in a dialogue when you log in.

I will show you how to add more lines of text

2 lines of text
Quote
talk2("Welcome to RuneWorld","Follow the rules and read the help guide",0);

3 lines of text
Quote
talk3("Welcome to RuneWorld","Follow the rules and read the help guide","LALALALALALA",0);

4 lines of text
Quote
talk4("Welcome to RuneWorld","Follow the rules and read the help guide","LALALALALALA","LALALALALALALA",0);


For the 3 and 4 lined text to work you may need theese method's Other wise you will get errors

Quote
   public void talk3(String text, String text2, String text3, int npc) {
      sendFrame200(4901, 591);
      sendFrame126(GetNpcName(npc), 4902);
      sendFrame126("", 4903);
      sendFrame126(text, 4904);
      sendFrame126(text2, 4905);
      sendFrame126(text3, 4906);
      sendFrame75(npc, 4901);
      sendFrame164(4900);
   }
   public void talk4(String text, String text2, String text3,  String text4, int npc) {
      sendFrame200(4901, 591);
      sendFrame126(GetNpcName(npc), 4902);
      sendFrame126(text, 4903);
      sendFrame126(text2, 4904);
      sendFrame126(text3, 4905);
      sendFrame126(text4, 4906);
      sendFrame75(npc, 4901);
      sendFrame164(4900);
   }

Of course you can figure where the text goes.
The " 0 " at the very end of each code is the npc ID you want it to show.  In my case Mines "Hans"

Pictures..

The Dialogue In motion.


After you click " Click here to continue"



Please Post if you Dont understand me i will try my hardest to help you.
Errors will be fixed over team viewer (But you really shouldnt get errors)

IF SOMEBODY ELSE GETS THIS WORKING CAN YOU POST A PIC TO PROVE IT WORKS PLEASE

This is basic and Is easy to figure out but once again it has not been posted yet.
« Last Edit: March 30, 2011, 12:32:07 am by AdotSells »

Share on Bluesky Share on Facebook


Offline Sam

  • Bandos Member
  • *
  • Posts: 372
  • Rep 1
    • View Profile
Re: Npc Dialogue on login.
« Reply #1 on: March 29, 2011, 01:19:22 am »
Real good job!
Well done, thanks for adding all these tutorials/snippets, it's really helping the community!

Offline AdotSells

  • Firecape Member
  • *
  • Posts: 300
  • Rep 4
    • View Profile
Re: Npc Dialogue on login.
« Reply #2 on: March 29, 2011, 01:22:17 am »
Its no problem.
Tbh its basic to me ..But it could be something someones always dreamed of but not able to do.

Offline Sajon

  • Rune Member
  • *
  • Posts: 166
  • Rep -1
  • Never Back down
  • Location: United Kingdom
    • View Profile
Re: Npc Dialogue on login.
« Reply #3 on: March 29, 2011, 01:29:52 am »
and where do i find that?

Offline AdotSells

  • Firecape Member
  • *
  • Posts: 300
  • Rep 4
    • View Profile
Re: Npc Dialogue on login.
« Reply #4 on: March 29, 2011, 01:32:25 am »
and where do i find that?

Sorry mate i updated the Thread.

Offline Ferp

  • Dragon Member
  • *
  • Posts: 238
  • Rep 10001
  • Making the impossible, possible.
  • Location: Canada
    • View Profile
Re: Npc Dialogue on login.
« Reply #5 on: March 29, 2011, 05:25:33 am »
Looks good, I upped your fame for helping out so much recently.


Offline Holy

  • Adamant Member
  • *
  • Posts: 98
  • Rep 0
  • The Next Lionel Messi.
  • Location: Written in the stars,Million miles away...
    • View Profile
Re: Npc Dialogue on login.
« Reply #6 on: March 29, 2011, 06:24:49 am »
Pretty good,easy guide, good job mate  ;;)
-Holy

Offline AdotSells

  • Firecape Member
  • *
  • Posts: 300
  • Rep 4
    • View Profile
Re: Npc Dialogue on login.
« Reply #7 on: March 29, 2011, 11:04:06 am »
Thanks guys (;

Offline Kyle

  • Administrator
  • Torva Member
  • *
  • Posts: 1636
  • Rep 10
    • View Profile
Re: Npc Dialogue on login.
« Reply #8 on: March 29, 2011, 04:01:28 pm »
Nice1, keep it up. :)

Offline AdotSells

  • Firecape Member
  • *
  • Posts: 300
  • Rep 4
    • View Profile
Re: Npc Dialogue on login.
« Reply #9 on: March 29, 2011, 04:03:02 pm »
Thanks :)

Offline The Unholy

  • Steel Member
  • *
  • Posts: 36
  • Rep 4
    • View Profile
Re: Npc Dialogue on login.
« Reply #10 on: March 29, 2011, 05:14:10 pm »
Very basic, but it'll help those that need it, so well done  :tf:

Offline AdotSells

  • Firecape Member
  • *
  • Posts: 300
  • Rep 4
    • View Profile
Re: Npc Dialogue on login.
« Reply #11 on: March 29, 2011, 09:51:44 pm »
Thanks

Offline Cinodor

  • I'm Awesome
  • Veteran
  • Pernix Member
  • *
  • Posts: 494
  • Rep 15
  • I Do Graphics To.
  • Location: GMT -6 (Oklahoma)
    • View Profile
Re: Npc Dialogue on login.
« Reply #12 on: March 29, 2011, 11:53:37 pm »
I'm going too give you 24 Hours to edit, before I lock it since this is your first warning.

Please read the Tutorial Section rules here.
http://www.rune-kingdom.org/index.php?topic=285.0
Signature Loading.. Please Wait..

Offline Kyle

  • Administrator
  • Torva Member
  • *
  • Posts: 1636
  • Rep 10
    • View Profile
Re: Npc Dialogue on login.
« Reply #13 on: March 30, 2011, 03:10:08 pm »
Removed that rule, was un-needed. Tutorials are tutorials.

Offline Tampon Abuse

  • Dragon Member
  • *
  • Posts: 193
  • Rep 1
  • All vote for Rune-Kingdom!
  • Location: Oklahoma, Oklahoma City
    • View Profile
Re: Npc Dialogue on login.
« Reply #14 on: April 04, 2011, 06:07:07 am »
Nice clean Tut

Everyone Vote For RUNE-KINGDOM at http://www.mmorpgtop200.com/in.php?site=6792