phBot Plugins
Search…
NPC
This function returns all nearby NPCs and teleporters.

Usage

get_npcs()

Returns

None or an object containing all nearby NPCs and teleporters.
  • The object can be empty.
  • The key in the object is the NPCs ID.
1
{
2
240: {
3
'servername': 'NPC_WC_SMITH',
4
'name': 'Blacksmith Agol',
5
'model': 2051
6
},
7
280: {
8
'servername': 'NPC_CH_GACHA_MACHINE',
9
'name': 'Magic POP',
10
'model': 9251
11
},
12
85: {
13
'servername': 'NPC_WC_POTION',
14
'name': 'Herbalist Bori',
15
'model': 2053
16
},
17
279: {
18
'servername': 'NPC_CH_EVENT_KISAENG1',
19
'name': 'Event So-Ok',
20
'model': 3861
21
},
22
24: {
23
'servername': 'NPC_WC_SPECIAL',
24
'name': 'Specialty Shop Elder Leegak',
25
'model': 2059
26
},
27
281: {
28
'servername': 'NPC_CH_GACHA_OPERATOR',
29
'name': 'Magic POP Guide Gori',
30
'model': 9252
31
},
32
282: {
33
'servername': 'NPC_BATTLE_ARENA_MANAGER',
34
'name': 'Arena Manager',
35
'model': 24642
36
},
37
29: {
38
'servername': 'NPC_WC_DOCTOR',
39
'name': 'Merchant Associate Leegeuk',
40
'model': 2065
41
}
42
}
Copied!

NPC Goods

This function returns all of the items associated with the NPC.

Usage

get_npc_goods(model)

Returns

None or a dictionary of NPC goods.
1
goods = get_npc_goods(7537)
2
model = goods[0][0]['model'] # model of page 0 / slot 0 (19693)
Copied!
1
{
2
0: {
3
0: {
4
'name': 'Blaze Blade',
5
'servername': 'ITEM_CH_BLADE_08_A_RARE_HONOR',
6
'model': 19693
7
},
8
1: {
9
'name': 'Blaze Blade',
10
'servername': 'ITEM_CH_BLADE_08_B_RARE_HONOR',
11
'model': 19694
12
},
13
2: {
14
'name': 'Blaze Blade',
15
'servername': 'ITEM_CH_BLADE_08_C_RARE_HONOR',
16
'model': 19695
17
},
18
3: {
19
'name': 'Moon Bow',
20
'servername': 'ITEM_CH_BOW_08_A_RARE_HONOR',
21
'model': 19711
22
},
23
4: {
24
'name': 'Moon Bow',
25
'servername': 'ITEM_CH_BOW_08_B_RARE_HONOR',
26
'model': 19712
27
},
28
5: {
29
'name': 'Moon Bow',
30
'servername': 'ITEM_CH_BOW_08_C_RARE_HONOR',
31
'model': 19713
32
},
33
6: {
34
'name': 'Iranggjingun Pike',
35
'servername': 'ITEM_CH_SPEAR_08_A_RARE_HONOR',
36
'model': 19699
37
},
38
7: {
39
'name': 'Iranggjingun Pike',
40
'servername': 'ITEM_CH_SPEAR_08_B_RARE_HONOR',
41
'model': 19700
42
},
43
8: {
44
'name': 'Iranggjingun Pike',
45
'servername': 'ITEM_CH_SPEAR_08_C_RARE_HONOR',
46
'model': 19701
47
},
48
9: {
49
'name': 'Devil Sword',
50
'servername': 'ITEM_CH_SWORD_08_A_RARE_HONOR',
51
'model': 19687
52
},
53
10: {
54
'name': 'Devil Sword',
55
'servername': 'ITEM_CH_SWORD_08_B_RARE_HONOR',
56
'model': 19688
57
},
58
11: {
59
'name': 'Devil Sword',
60
'servername': 'ITEM_CH_SWORD_08_C_RARE_HONOR',
61
'model': 19689
62
},
63
12: {
64
'name': 'Polearm',
65
'servername': 'ITEM_CH_TBLADE_08_A_RARE_HONOR',
66
'model': 19705
67
},
68
13: {
69
'name': 'Polearm',
70
'servername': 'ITEM_CH_TBLADE_08_B_RARE_HONOR',
71
'model': 19706
72
},
73
14: {
74
'name': 'Polearm',
75
'servername': 'ITEM_CH_TBLADE_08_C_RARE_HONOR',
76
'model': 19707
77
}
78
},
79
1: {
80
0: {
81
'name': 'Honor Alchemy Stone (8th degree)',
82
'servername': 'ITEM_ETC_ARCHEMY_MAGICSTONE_REPAIR_08',
83
'model': 19717
84
}
85
}
86
}
Copied!
Last modified 2yr ago