Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Rappelz > Rappelz Private Server
You last visited: Today at 14:11

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[HowTo] Custom NPCs

Discussion on [HowTo] Custom NPCs within the Rappelz Private Server forum part of the Rappelz category.

Reply
 
Old   #1


 
Xijezu's Avatar
 
elite*gold: 0
Join Date: May 2011
Posts: 5,084
Received Thanks: 3,458
[HowTo] Custom NPCs

Hello,

After I saw this question alot, I thaught about thinkin' to write some BEGINNING, this will be NOT a Copy'n'Paste Tutorial, you have to do those things ON YOUR OWN!

But now to my tut:

What we need:
  • A program to edit .lua's
  • Databaseaccess
  • Brain.exe (Note: If you can't find it: Give up.)

Part 1: Database
- If you don't want to use disabled NPC's, then skip this step.

Well, I know, it's the wrong beginning, but I said it before: This is not a Copy'n'Paste-Tut.

First of all search for a disabled NPC (select * from npcresource where local_flag IS NOT '0')
Here you have to edit x, y, contact_script and local_flag.
X & Y should be clear, local_flag, too. If you don't know, what you have to replace here, give up. :3
Now contact_script:
Think about some good name, for our example we'll take "NPC_DarknessFight".
Here you have to insert "NPC_DarknessFight()" - "(" & ")" are important!

Part 2: Lua-Files
Now you have the choise:
Use a existing .lua, or create a new one.

If you want to create a new one, you have to put this at the beginning:
Code:
function get_module_name()
             return "DESCRIPTION"
             -- Example:
             -- return "DarknessFight"
end
Now we gonna create the Display for the NPC.

First of all, you must remember the Databasename, in this case "NPC_DarknessFight".

This will be our beginning

Code:
-- Initalize Script
function get_module_name()
return "DarknessFight"
end

-- Start NPC
function NPC_DarknessFight() -- ( & ), again important, else it wont work!
-- ToDo: Function
end
Now we have the base, this part is the function of when you double-click on your NPC.
But we want that awesome window, how can we get this?

Code:
dlg_title( "Xijezu" )
dlg_text( "Hello, nice to meet you. And now GTFO." )
dlg_menu( "Menu 1", 'open_market("lalalalala")' )
dlg_menu( "Uhuh, close this shit! :D", '' )
Selfexplaining?

So the full code would be this:

Code:
-- Initalize Script
function get_module_name()
return "DarknessFight"
end

-- Start NPC
function NPC_DarknessFight() -- ( & ), again important, else it wont work!
dlg_title( "Xijezu" )
dlg_text( "Hello, nice to meet you. And now GTFO." )
dlg_menu( "Menu", 'open_market("lalalalala")' )
dlg_menu( "Uhuh, close this shit! :D", '' )
end
Now you got a new NPC.
If you want a custom function, like add state or insert item, then you have to write a new function

Code:
function test_function()
warp(99999, 99999) -- This will warp you into CV
end
You can use this with this little change:
Code:
dlg_menu( "Menu", 'test_function()' )
Understood?
Good.

Questions?
Yes? Then use search.

Greets,

Xijezu
Xijezu is offline  
Thanks
37 Users
Old 12/02/2011, 14:15   #2
 
TheOnlyOneRaskim's Avatar
 
elite*gold: 0
Join Date: Nov 2011
Posts: 978
Received Thanks: 1,011
Wasted Time, i bet 1.000.000$ in the Next 2 week´s, some noob`s will ask, "How add NPC???!!".


But for the People who really want to learn, it`s good.
TheOnlyOneRaskim is offline  
Thanks
2 Users
Old 12/02/2011, 14:16   #3
 
elite*gold: 0
Join Date: Dec 2011
Posts: 6
Received Thanks: 0
Xijezu can you send me your skype in pm?
ILoveShyla<3 is offline  
Old 12/02/2011, 14:17   #4


 
Xijezu's Avatar
 
elite*gold: 0
Join Date: May 2011
Posts: 5,084
Received Thanks: 3,458
Quote:
Originally Posted by TheOnlyOneRaskim View Post
Wasted Time, i bet 1.000.000$ in the Next 2 week´s, some noob`s will ask, "How add NPC???!!".
I know -.-

Quote:
Originally Posted by TheOnlyOneRaskim View Post
But for the People who really want to learn, it`s good.
Thats the reason why I wrote this tut. ^_^
Xijezu is offline  
Thanks
1 User
Old 12/02/2011, 14:23   #5
 
elite*gold: 0
Join Date: Sep 2011
Posts: 62
Received Thanks: 9
Xijezu ok thats good but )=== ineed how add sql in Data Base Screenshost*
mahmoudnasser is offline  
Old 12/02/2011, 14:29   #6


 
Xijezu's Avatar
 
elite*gold: 0
Join Date: May 2011
Posts: 5,084
Received Thanks: 3,458
Quote:
After I saw this question alot, I thaught about thinkin' to write some BEGINNING, this will be NOT a Copy'n'Paste Tutorial, you have to do those things ON YOUR OWN!
Quote:
First of all search for a disabled NPC (select * from npcresource where local_flag IS NOT '0')
Here you have to edit x, y, contact_script and local_flag.
X & Y should be clear, local_flag, too. If you don't know, what you have to replace here, give up. :3
Selfexplaining.^_^
Xijezu is offline  
Old 12/02/2011, 14:45   #7


 
Xijezu's Avatar
 
elite*gold: 0
Join Date: May 2011
Posts: 5,084
Received Thanks: 3,458
Quote:
Originally Posted by speedy-nl View Post
Brain.exe (Note: If you can't find it: Give up.)

where can i find this ?
speedy, I lol'd.
But then I saw your username... Bad joke

Just like raskim said:
This is just for people who won't copy'n'paste, also for people which wanna learn a bit. :3
Xijezu is offline  
Thanks
1 User
Old 12/02/2011, 15:44   #8
 
elite*gold: 0
Join Date: Jun 2011
Posts: 95
Received Thanks: 11
You are the best man !
qaaah is offline  
Old 12/03/2011, 05:56   #9


 
Xijezu's Avatar
 
elite*gold: 0
Join Date: May 2011
Posts: 5,084
Received Thanks: 3,458
Who was successful to create a custom NPC after this little tut?
Xijezu is offline  
Thanks
2 Users
Old 12/03/2011, 07:10   #10
 
Saelt's Avatar
 
elite*gold: 0
Join Date: Sep 2011
Posts: 98
Received Thanks: 31
I have enable the npc, set X, Y, but when i double-click on, nothing happen :0 x) got an idea ?
Saelt is offline  
Old 12/03/2011, 07:17   #11


 
Xijezu's Avatar
 
elite*gold: 0
Join Date: May 2011
Posts: 5,084
Received Thanks: 3,458
Quote:
Now contact_script:
Think about some good name, for our example we'll take "NPC_DarknessFight".
Here you have to insert "NPC_DarknessFight()" - "(" & ")" are important!
You forgot this.
Xijezu is offline  
Old 12/03/2011, 08:08   #12
 
elite*gold: 0
Join Date: Apr 2010
Posts: 389
Received Thanks: 294
how add npc plez tell me i want add npc my server

(another noob asking )

Thanks for the tut but as raskim said there will be noobs asking
Strange2010 is offline  
Old 12/03/2011, 10:08   #13
 
Saelt's Avatar
 
elite*gold: 0
Join Date: Sep 2011
Posts: 98
Received Thanks: 31
Quote:
Originally Posted by Xijezu View Post
You forgot this.
No thats the problem. I've got an idea, i'm testing it .
Thx for this.
Saelt is offline  
Old 12/03/2011, 13:39   #14
 
Saelt's Avatar
 
elite*gold: 0
Join Date: Sep 2011
Posts: 98
Received Thanks: 31
Thx it is working
Saelt is offline  
Old 12/07/2011, 14:49   #15
 
haxti's Avatar
 
elite*gold: 0
Join Date: Jun 2010
Posts: 573
Received Thanks: 163
you have to put in the correct script in the db. Furthermore the script itself needs to be correct
haxti is offline  
Reply


Similar Threads Similar Threads
5165 Custom NPCS
02/19/2011 - CO2 Private Server - 3 Replies
How do you make a npc talk in 5165 source? I know how to edit the face type, mech type etc. But where do you go to make them talk. :) Thanks in advance.
Custom Items,Maps,Npcs?
11/30/2010 - Ragnarok Online PServer Hosting - 17 Replies
Hallo wollt mehrere sachen auf einmal fragen ;) 1. wie setz ich ein warp npc auf ... der in allen dungens/towers warp 2.wie fuege ich Custom Items ein 3.Wo bekomm ich Custom items ueberhapt her 4.man kann ja von den anderen server .. die custom items irgendwie nehmen .. und maps aber wie geht das? ... ;)
[Question] Custom NPCs
09/18/2008 - Flyff Private Server - 0 Replies
Hey sorry I can't really read german and I couldnt translate with babelfish what Alasami wrote because it's an image. But could someone guide me on how to make a Custom NPC seller or a jobchange NPC. Also if it requires more coding then using the database could someone give me an example on how to code one. I saw on Ragezone that Vulcan used LUA but im wondering if someone could release an open source script of a custom NPC. Would be greatly appreciated, Thanks, Phil
WoW, Mangos: custom NPCs?
07/09/2008 - WoW Private Server - 0 Replies
Mangos, Rev 5966, WoW 2.4.2 Creating a custom NPC using the WoW Model Viewer My idea in short: 1.) create a NPC after my fancy 2.) save and "translate" the information into a sql file 3.) batch the file; thus making it selectable for my 'new' NPC's DisplayID... If so, do you think it's a lot of work making this possible?
How can i put Custom NPCs GM shops in my server?
04/16/2008 - Lin2 Private Server - 4 Replies
Hello, i have made my server work fine now. How can i put custom GM shops and Npc's buffers files? can anyone show me and tell me correctly how can i do that please?



All times are GMT +2. The time now is 14:11.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.