How to do this? :/
#1

Hello, I need a system for a DM server. I Will explain ... I want that every few kills the player will receive a TextDraw message. Example: When you do 10 kills it will say > "Level 1: Apprentice" and so on. Help please, Thanks
Reply
#2

If you have a register system (else this wouldn't work):

pawn Код:
if(PlayerInfo[playerid][pKills] == 10) { //your code ...
// you can add PlayerInfo[playerid][pKills]++; so you don't get bugs like leveling up each time you log in if you have 10 kills or whatever... just saying
if(PlayerInfo[playerid][pKills] = 500) { // your code ..
And repeat. Look up Kush's tutorial on how to make a DIALOG ACCOUNT SYSTEM.
It will help you out.
Reply
#3

Also add this on OnPlayerDeath if you don't have it:

pawn Код:
PlayerInfo[playerid][pDeaths]++;
PlayerInfo[killerid][pKills]++; // increase kills by 1
Код:
This forum requires that you wait 120 seconds between posts. Please try again in 22 seconds.
This forum requires that you wait 120 seconds between posts. Please try again in 5 seconds.
Worst enemy :X
Reply
#4

Better to read the forum rules. Just edit your previous post instead of making a new one and double post.

And that will cause problems.
pawn Код:
PlayerInfo[killerid][pKills]++;
It should be
pawn Код:
if(killerid != INVALID_PLAYER_ID) PlayerInfo[killerid][pKills]++;
Reply
#5

Quote:
Originally Posted by jNkk
Посмотреть сообщение
If you have a register system (else this wouldn't work):

pawn Код:
if(PlayerInfo[playerid][pKills] == 10) { //your code ...
// you can add PlayerInfo[playerid][pKills]++; so you don't get bugs like leveling up each time you log in if you have 10 kills or whatever... just saying
if(PlayerInfo[playerid][pKills] = 500) { // your code ..
And repeat. Look up Kush's tutorial on how to make a DIALOG ACCOUNT SYSTEM.
It will help you out.
Yes i have a register system, Iґll try that but where do i need tu place it
Reply
#6

pawn Код:
if(PlayerInfo[killerid][pKills] == 10) { //your code ...
// you can add PlayerInfo[playerid][pKills]++; so you don't get bugs like leveling up each time you log in if you have 10 kills or whatever... just saying
if(PlayerInfo[killerid][pKills] = 500) { // your code ..
Under OnPlayerDeath
Reply
#7

Quote:
Originally Posted by [HRD]Mar1
Посмотреть сообщение
pawn Код:
if(PlayerInfo[killerid][pKills] == 10) { //your code ...
// you can add PlayerInfo[playerid][pKills]++; so you don't get bugs like leveling up each time you log in if you have 10 kills or whatever... just saying
if(PlayerInfo[killerid][pKills] = 500) { // your code ..
Under OnPlayerDeath
What goes on "your code"
Reply
#8

Quote:
Originally Posted by Lauder
Посмотреть сообщение
What goes on "your code"
Tell me what enum you have,
or what admin system you use ?
Reply
#9

Quote:
Originally Posted by [HRD]Mar1
Посмотреть сообщение
Tell me what enum you have,
or what admin system you use ?
1) Whats "enum"
2) My Admin system is very simple I meda it my self from I tutorial It only has /ban /kick /pm and some other commands that are to play music and all that.
3) My register system is also very simple and I gotted from this tutorial: https://sampforum.blast.hk/showthread.php?tid=273088
Reply
#10

Please contact me and we will solve this for sure.
Skype:junkiez.doriftar.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)