zade_o Posted November 15, 2008 Author Share Posted November 15, 2008 Ok, the NPC the script involves is NPC #5 on map #3\. In my list of created NPCs he is #1\. (keep that in mind)``` Dim mc If GetMapNpcHP(3,1) > 0 Then mc=mc+1 End If If GetMapNpcHP(3,2)>0 Then mc=mc+2 End If If GetMapNpcHP(3,3)>0 Then mc=mc+3 End If If GetMapNpcHP(3,4)>0 Then mc=mc+4 End If dim added added=Rand(100,300+(200*mc)) dim curhp dim newhp curhp = GetMapNpcHP(3,5) newhp = GetMapNpcHp(3,5)+added If newhp>GetNpcMaxHP(1) Then newhp=GetNpcMaxHP(1) End If 'SetMapNpcHP(3,1,newhp) 'SendNPC(3,5) Call MapMsg(3,"Old HP: " & curhp &" New HP: " & newhp,4) mc=0```That works perfectly. However, if I uncomment those two commented commands, it fails and nothing shows up.Soooo….what's the problem ? Link to comment Share on other sites More sharing options...
zade_o Posted November 15, 2008 Author Share Posted November 15, 2008 ok comeone. someone has to know what the issue is?I took out the the SendNPC command as well. so now there's only an issue with this lineSetMapNPC(3,1,newhp)Any suggestions?…. Link to comment Share on other sites More sharing options...
AdrianC Posted November 16, 2008 Share Posted November 16, 2008 TrySetMapNpcHP(3,1,int(newhp))I'm not really familiar with these commands, so I can't help that much. Link to comment Share on other sites More sharing options...
zade_o Posted November 16, 2008 Author Share Posted November 16, 2008 Nope, still doesn't work =/ Link to comment Share on other sites More sharing options...
dg1423 Posted November 16, 2008 Share Posted November 16, 2008 lol, you didn't put Call, tryCall SetMapNpcHP(3,1,newhp)Call SendNPC(3,5) Link to comment Share on other sites More sharing options...
AdrianC Posted November 16, 2008 Share Posted November 16, 2008 Can't believe I missed that. Link to comment Share on other sites More sharing options...
zade_o Posted November 16, 2008 Author Share Posted November 16, 2008 OMFG. I can't believe I missed that too. I kinda wanna quit programming now….Duck...............Delete this thread so nobody sees my idiocy O.o Link to comment Share on other sites More sharing options...
dg1423 Posted November 17, 2008 Share Posted November 17, 2008 well, does it work now? xD Link to comment Share on other sites More sharing options...
zade_o Posted November 17, 2008 Author Share Posted November 17, 2008 Yeah that's what the problem was haha. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now