![]() |
|
|
#1 |
|
Архивный участник
Join Date: Jun 2006
Posts: 20
|
Is there a way that i can make a NPC level the person that is talking to hit. I guess its going to have to be through the AI, if someone could help me, like a guide, possibly code samples, etc, i would greatly apperciate it.
~James |
|
|
|
|
#2 |
|
Архивный участник
Join Date: Sep 2005
Posts: 1,014
|
Here u have an example, take me 2 minutes to code...
Is C1 NASC AI, need to compile... i dont test it but it must work... AI Code:
class change_level : citizen
{
parameter:
string fnHi = "change_level001.htm";
handler:
EventHandler TALKED(talker)
{
ShowPage(talker,fnHi);
}
EventHandler MENU_SELECTED(ask, reply, talker)
{
if (ask == 1) IncrementParam(talker, @PARAM_EXP, reply);
if (ask == 2) IncrementParam(talker, @PARAM_SP, reply);
}
}
Code:
<html><head><body> Change Level NPC: <br><a action="bypass -h menu_select?ask=1&reply=300000000">Get EXP (300kk)</a> <br><a action="bypass -h menu_select?ask=2&reply=1000000">Get SP (1kk)</a> </body></html> |
|
|
|
|
#3 |
|
Архивный участник
Join Date: Jun 2006
Posts: 20
|
Sweet, thanks very much, is there much difference from C1 -> C4 NASC?
|
|
|
|
|
#4 |
|
Архивный участник
Join Date: Jun 2005
Posts: 374
|
Yeah. You probably don't have C4 NASC.
|
|
|
|
|
#5 |
|
Архивный участник
Join Date: Jun 2006
Posts: 20
|
>.< ok, thanks anyway, when i figure out how to compile it, ill test it, if there any other suggestions, go ahead and post them, ill still check back, thanks again
|
|
|
| Thread Tools | Search this Thread |
| Display Modes | |
|
|