Announcement

Collapse
No announcement yet.

my first solo-project, needs supervision

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    my first solo-project, needs supervision

    This is my first 'made from scratch' project, and I need someone to check up on my script every now and then to catch any errors i might have made along the way, I've tried to put a hefty amount of comments everywere I feel nesecery, and I will update this post as I make more chuncks

    first question thoguh is....what class shoudl this extend?

    Code:
    //==========================================================
    //  Leveling system
    //  used to determine affects 
    //  of stats on chracter performance
    //  By: ├┤MMT├┤Kojin               todo - //::
    //==========================================================
    class RPGstats extends ????? //::
    
    var str  //affects atkp1, defence, and hp  - slightly affects atkp2
    var dex  //affects atkp2, atkp3, dodge, aspd, and mspd - slightly affects atkp1
    var intl //affects magikp, and MP
    var foc  //affects magikd, hit, and craftingr
    var inst //affects crit2, skilld, and craftings
    var luk  //affects droprate, crit1
    var float atkp1   //damage for all types of swords, spears, crossbows, maces and fists(%50)
    var float atkp2   //damage for katars, knives, and fists(%50)
    var float atkp3   //damage for all bows and cross bows
    var float dodge   //affects the chance that an enemy will do no damage, even if hit
    var float defence //lowers amount of damage done by atkp1, atkp2, and atkp2
    var float magikp  //damage for magik attacks, and wands/staves
    var float magikd  //lowers damage done by magikp
    var float hit     //raises chance to hit an enemy, provided hit is succesful
    var float aspd    //affects the speed the attack animations will play at, and affects time between animation replay/hit
    var float mspd    //raises players moving speed - max = 1800 (flying = 4500)
    var float craftings //affects the outcome of a crafted item, provided crafting was sucessful
    var float craftingr //affects chance of succesfully crafting, if fails, items used are destroyed
    var float crit1   //affects critical hit rate for atkp1 and atkp3 (crit1 = *2 damage)
    var float crit2   //affects critical hit rate for atkp2 (crit 2 = *4 damage)
    var float droprate  //affects the pre-determined item drop rates of enemys, 1 luk = +0.05% drop rate
    var hp            //raises max health
    var mp            //raises max MP (an ammo type)
    var exp           //when reaches 100%, level up, give pre-determined # of stat points at certain levels
                      //exp % is determined x/y, every level, y is increased by 3% - at level 1, y is 1500
    
    function

    #2
    First off, I would guess, is it your intent to make this a whole new gametype, or a mutator?

    Comment


      #3
      I have no idea about the technical side of things, but I would like to impart one piece of sound advice on you: start with the things that post the biggest risks for failure.

      You appear to have invested considerable time in designing this system. It would be a tremendous loss of time if you kept on expanding and refining this for three months, only to discover that what you want cannot be done. I suggest you start very simple, with nothing but a knife and the "hit" stat. See if you can develop this rudimentary knife and stab bots with it, with success depending on your "hit" stat. Once that is working, the rest should be comparatively safe.

      Comment


        #4
        well, i know for a fact that it can be done, because all im doing is tossing in some algebraic equations into stuff thats alread there, like increasing damage, more max hp, increase max ammo, etc.

        also, Ive seen this done before, my stat system is just a much more complex version of the stat system in the UT2003RPG mutator.

        Also, i wasn't planning on making this huge-**** script and then slappin it on and running it, i was gonna make alot of the variables commented text, and test things out 1 at a time, i jstu didnt do that here as not to confuse people =)

        Comment


          #5
          If you want to save all those you're going to have to either make them config vars or turn the whole class into a DataObject and use the game saving feature.

          Comment


            #6
            Extend Object like AM said, and make it a data object. I believe the save and load functions are in Level or GameInfo, I cant remember right off the top of my head. There are examples when UT2004 deals with profiles and such, theres a variable called CurrentGameProfile (I think it's called) in GameInfo, and it gets used by the profile system (obviously), so see how its done. Its pretty simple, reliable, but still kind of complicated. The HighScores are also data objects, if I recall (I know the ones we use in our mod are data objects, but we dont save them, only load).

            Also when dealing with things like stats, be sure to mind your OOP. This is very good place to practice encapsulation.

            Comment


              #7
              you know i was touching down on that subject with a freind of mine, and, well, I was going to make the Player profiles server side only, to that no1 can go in and edit their character from their own computer, I even haev an account system that lets players create their own accounts, and be sent to my mySQL...lets them ahve 3 characters, and it saves every lil detail when they log off or change maps or every 5 minutes

              Comment

              Working...
              X