Register for your free account! | Forgot your password?

You last visited: Today at 15:35

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

Advertisement



Npc Help?

Discussion on Npc Help? within the CO2 Private Server forum part of the Conquer Online 2 category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Mar 2010
Posts: 91
Received Thanks: 5
Npc Help?

Well im new at this and i have no idea what im doing but i messed up i cant put what i did because i just deleted it all i tried to make an npc that makes people fight
Heres exactly what he's SUPPOSED to do but i need help i just started so i dont know what im doing
1. Get 2 people 1 vs 1
2. both go to npc each pay 100k cps
3. teleports them to .Arcos release of the ship map(i dont know how to put in the source)
4. makes them fight to death(no pot,changing weapons, and only allowed to use fb/ss<--this i had trouble with)
5.Winner gets 200k cps loser gets nothing
PLz if anyone could help me i know how to not allow them to use pots and change weapons but im having trouble with the teleportation and the disabling of the skills.
Plz if anyone could help me id be very grateful because i have alot to fix and add
biohazardous is offline  
Old 09/20/2010, 22:18   #2
 
elite*gold: 21
Join Date: Jul 2005
Posts: 9,193
Received Thanks: 5,376
I'd do something like a list of maps where pots/skills are not allowed. Then in your item usage code, check if they are on a map that cannot use pots on and if so, do not remove item and simply return;


Same for skills. Check if they can use skills on that map and if not, don't let them use anything except ss/fb.

Personally I'd do something more like an enum for SkillUsage on a map so that you can permit very specific things.

Eg

if(Program.Maps[CLient.Map].Skilluse = Enum.OnlyFbSs)
if(SkillId != (ushort)SkillType.Ss || SKillId != (ushort)SkillType.Fb)
return;

Would be the most efficient way to write your map permissions as far as I can tell.

Requires alot of re-writing to do things that way but will save you time in the long run (aka how I plan to write mine)
pro4never is offline  
Thanks
1 User
Old 09/20/2010, 23:08   #3
 
elite*gold: 0
Join Date: Mar 2010
Posts: 91
Received Thanks: 5
Quote:
Originally Posted by pro4never View Post
I'd do something like a list of maps where pots/skills are not allowed. Then in your item usage code, check if they are on a map that cannot use pots on and if so, do not remove item and simply return;


Same for skills. Check if they can use skills on that map and if not, don't let them use anything except ss/fb.

Personally I'd do something more like an enum for SkillUsage on a map so that you can permit very specific things.

Eg

if(Program.Maps[CLient.Map].Skilluse = Enum.OnlyFbSs)
if(SkillId != (ushort)SkillType.Ss || SKillId != (ushort)SkillType.Fb)
return;

Would be the most efficient way to write your map permissions as far as I can tell.

Requires alot of re-writing to do things that way but will save you time in the long run (aka how I plan to write mine)
Where do i put this in the ship map?
biohazardous is offline  
Reply




All times are GMT +2. The time now is 15:35.


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.