rathena/doc/sample/npc_live_dialogues.txt
Euphy c610f5b15c * Added some iRO Eden Group NPCs. (credits: -SkittleNugget-)
- This consists of a few traders, warpers, cashshop-related scripts, and duplicates from various locations.
- There are a lot of placeholders and some entirely missing scripts; these may be added later, but we don't intend to implement all of iRO's custom features.
- Some of the item sprites may be unviewable without iRO's data.grf.

* Minor database updates:
- Corrected all *_C (rental) equipment entries; to be updated later on with VIP bonuses.
- Fixed some bHpDrainRate item_db entries. (incl. bugreport:8049)
- Fixed a mob_skill_db entry. (bugreport:8050)

* Other changes:
- Renamed 'F_RandMes' to 'F_Rand', to clear up any confusion. (follow-up 66a2bfd)
- Small changes in Armor Enchanter script (thanks to Emistry for pointing it out :p).

Signed-off-by: Euphy <euphy@rathena.org>
2013-09-06 00:22:41 -04:00

54 lines
1.8 KiB
Plaintext

//===== rAthena Script =======================================
//= Sample: Live Dialogue
//===== By: ==================================================
//= Lupus
//===== Current Version: =====================================
//= 20130905
//===== Description: =========================================
//= An example of an NPC with live dialogue.
//= Note: This relies on Global_Functions.txt to run.
//============================================================
prontera,167,177,5 script Luppy 1107,{
mes "[Luppy]";
// Say a random greeting from Global_Functions.txt
mes callfunc("F_Hi");
// Say a compliment according to player's gender
// 1st string is for FEMALE, 2nd for MALE
mes callfunc("F_Sex","What a beautiful lady!","What a handsome man!");
// Add some random greeting and goodbye into the menu
menu callfunc("F_Hi"),-, callfunc("F_Bye"),M_BYE;
mes "[Luppy]";
// Give a random prize from set list of items
if(@gotstuff){
// Again, say stuff according to player's gender
mes "I like "+callfunc("F_Sex","smiling ladies!","bloody pirates!");
// Show one of 3 emotion from the list (we added ,1 to show emotion over PLAYER's head)
emotion callfunc("F_Rand",e_scissors,e_kis,e_pat),1;
close;
}
// We set a temp var to give present just once. Player can get more by relogging.
set @gotstuff,1;
// Get item ID from the list of presents: Apple, Mastela Fruit, Yggdrasil Seed or Orange Juice
set @itemIDfromList, callfunc("F_Rand",512,522,608,620);
// Again, say stuff according to player's gender
mes "Hey, "+callfunc("F_Sex","sister!","brother!")+" I have "+getitemname(@itemIDfromList)+" for you!";
// Get the item from the list
getitem @itemIDfromList,1;
close;
M_BYE:
mes "[Luppy]";
// Add some random goodbye from Global_Functions.txt
mes callfunc("F_Bye");
close;
}