[HELP!] Hasnt been on Epvp yet!

04/05/2010 22:21 allizzel777#1
does anyone know how to add Redeem NPC in Co? i need that sooo badly
my servers yelling at me thats like the only thing i need lol
its 5165 btw!
04/05/2010 22:36 Arcо#2
I haven't played real conquer in a while, whats the redeem npc?
04/05/2010 22:47 pro4never#3
I think I know what he means... The newer patches, people who are red/black and get pk'd have their items retained and if they don't pay cps to get them back, the player who killed them can claim them after a week or something like that... If they do pay the cps then it goes to the person who killed them.

It would be a fairly complex system to code (as far as npcs go). You would need a new database (or flatfile if it's lotf and you haven't converted to sql) to store what item belonged to who, cp value for it, when the item was retained, who pk'd them and such...

Then When the player is killed you need to do a random chance calculation to see what item(s) are retained, remove it from the client, add it to the database, calculate the cp value of the item (based on your servers economy) and finally print the required msg's to players who are online...

Then add an npc to pay the required cps to get them back (in which case the cp has to be added to the account who killed them, again, FAR easier if you are using sql instead of flatfile), they get their item back, the item is removed from the retained items database and the msgs are printed out to the server.

Finally do a check lets say every hour to see if any of the items in the database have gone unclaimed for x amount of days. If so, allow the person who killed them to claim the item(s) from an npc and obviously print the msgs's out to server and update the database when the item is claimed.

Also possibly add a 30 day check to see if it's gone unclaimed and if so delete it all together (if not if people quit your server your database will just get bigger and bigger needlessly)


Those are all the steps to it I can think of... some of them will be a bit tricky but it shouldn't be THAAATT hard.
04/05/2010 23:08 PeTe Ninja#4
i haven't read the guys above me cuz im lazy but just to do this

just like equips have something called..

that saves as Lost Equips..

so then when they login it pops up as npc or whatnot and says you have a "...super w.e " and you can recieve it for ... "calc the price hre" ..

once they buy it delete the item from the lost equips save and whatnot..

if its past 30 days.. move the lost equips to reward equips on the char who killed him.
04/05/2010 23:17 allizzel777#5
someone should totally make it LOl
ok well another problem like
when im whispering people or talking on friend chat and someones name is typed in that box
it wont appear on my client when i send the message how do i fix that|?
04/05/2010 23:21 pro4never#6
1: No one is just gonna code something like that and release it... I mean it's possible it will be released someday but it's not a simple npc that someone can whip up in like 5-10 minutes... It's something people would generally keep for themselves.


2: The whisper thing sounds to me like your source doesn't have whisper coded properly at all... I'd look at coemu or another source (ANY source really) and get how whispers are handled in them. I think I saw that 5165 lotf uses something like if (ChatType == "Whisper") so you might wanna search for something similar to that.

You will want it to send the msg from you to whoever both on your own client and the person you are whispering. Should be a very simple fix.
04/06/2010 00:35 zTREME#7
The server fails with redeem npc!
end
04/06/2010 01:42 allizzel777#8
lol well its better then people going around droping there gears... when red named
ok but can some one teach me how to add an NPC? iv been trying but i dont understand it im trying to add Confiscator in jail but all i have ishis ID 4542 and thats all i can't figure out how to make him say anything or take out PKP and CPS
04/06/2010 04:22 .Beatz#9
Quote:
Originally Posted by allizzel777 View Post
lol well its better then people going around droping there gears... when red named
ok but can some one teach me how to add an NPC? iv been trying but i dont understand it im trying to add Confiscator in jail but all i have ishis ID 4542 and thats all i can't figure out how to make him say anything or take out PKP and CPS
Use my sig on how to make a NPC