Raised This Month: $ Target: $400
 0% 

Class help


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Werewolf
Senior Member
Join Date: Jan 2006
Location: Sweden
Old 03-12-2006 , 16:49   Class help
Reply With Quote #1

Hello.
This doesn't work. Can you help me please?
Code:
#if defined _myth_skills_included #endinput #endif #define _myth_skills_included new g_PlayerClass[33]; new g_PlayerXP[33]; new g_PlayerLevel[33]; new g_SkillUsed[33]; #define CLASS_NOTHING 0 #define CLASS_DEMON 1 #define CLASS_ANGEL 2 #define CLASS_SHAPESHIFTER 3 #define CLASS_PHOENIX 4 #define CLASS_WEREWOLF 5 #define CLASS_VAMPYRE 6 #define NUMCLASSES 7 new const CLASSES[NUMCLASSES][] = {     "None",     "Demon",     "Angel",     "Shapeshifter",     "Phoenix",     "Werewolf",     "Vampyre" } public classpowers(id) {     new level = g_PlayerLevel[id]     if(level == 0) return 1;     if(g_PlayerLevel[id] == 1)     {     set_user_health(id, 110)     }     if(g_PlayerLevel[id] == 2)     {     set_user_health(id, 120)     }     if(g_PlayerLevel[id] == 3)     {     set_user_health(id, 130)     }     if(g_PlayerLevel[id] == 4)     {     set_user_health(id, 140)     }     if(g_PlayerLevel[id] == 5)     {     set_user_health(id, 150)     }     if(g_PlayerLevel[id] == 6)     {     set_user_health(id, 160)     }     if(g_PlayerLevel[id] == 7)     {     set_user_health(id, 170)     }     if(g_PlayerLevel[id] == 8)     {     set_user_health(id, 180)     }     if(g_PlayerLevel[id] == 9)     {     set_user_health(id, 190)     }     if(g_PlayerLevel[id] == 10)     {     set_user_health(id, 200)     }     return PLUGIN_CONTINUE }
And if you wonder. I call this every round

And problem 2.
When I set that to 1 class it still gives to ALL classes in my mod.
What should I do?

Problem 3.
When I set xp, then if I set to example 10000000 xp then you don't raise any levels until you kill someone. Example. You are on level 0. I set xp to 100000 which is more than level 10's xp. You are still on level 0 but you raise levels for each kill instead.
Here is the code i set for the levels/xp
Code:
if(g_PlayerXP[id] == 100) g_PlayerLevel[id] = 1 if(g_PlayerXP[id] == 200) g_PlayerLevel[id] = 2 etc.
Werewolf is offline
 


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 20:14.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode