Need sum help at char creating with skill

Results 1 to 11 of 11
  1. #1
    Member r4ptor is offline
    MemberRank
    Jun 2006 Join Date
    BrazilLocation
    25Posts

    Need sum help at char creating with skill

    well in charserver.ccp have the code that create chars, basic is this

    DoSQL("INSERT INTO characters (account_name, char_name, face, hairStyle, sex) VALUES('%s','%s',%i,%i,%i)", thisclient->username, newname.c_str(), face, hairstyle, sex);

    right?
    i was tryng to make it insert the basic skills too
    11,12,13,14,15,16,17,18,19,20,21,22,25,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0

    so how can i put this into the code?
    i need make a new variable to receive the skills? or just put the numbers into the code, but if is this, how can i make it? XD, dont know very well c++

    DoSQL("INSERT INTO characters (account_name, char_name, face, hairStyle, sex,basic_skills) VALUES('%s','%s',%i,%i,%i,what here? XD)", thisclient->username, newname.c_str(), face, hairstyle, sex,11,12,13,14,15,16,17,18,19,20,21,22,25,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);



    thx everyone


  2. #2
    Sorcerer Supreme Caali is offline
    Member +Rank
    Sep 2006 Join Date
    263Posts
    Code:
     DoSQL("INSERT INTO characters (account_name, char_name, face, hairStyle, sex,basic_skills) VALUES('%s','%s',%i,%i,%i,'11,12,13,14,15,16,17,18,19,20,21,22,25,0,0,0,0,0,0 ,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0')", thisclient->username, newname.c_str(), face, hairstyle, sex);
    ... the basic skills are set as defaults in the mysql database...

  3. #3
    Member r4ptor is offline
    MemberRank
    Jun 2006 Join Date
    BrazilLocation
    25Posts
    not in the version im using XD
    hmm thx anyway caali

  4. #4
    Sorcerer Supreme zad67 is offline
    Member +Rank
    Jun 2006 Join Date
    Over Here!Location
    349Posts
    All you have to do is go into the table design mode using the table characters then find the basic_skills part and then in default put in the following then save.

    11,12,13,14,15,16,17,18,19,20,21,22,25,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0

  5. #5
    Member r4ptor is offline
    MemberRank
    Jun 2006 Join Date
    BrazilLocation
    25Posts
    talking about db, can someone give me a good db XD
    im using one that only have 33k XD, its very basic, dont have almost nothing =/
    i looked around in forum and found some, but most dont work with the navicat, dont know why =/ it just dont creat the tables

  6. #6
    Sorcerer Supreme zad67 is offline
    Member +Rank
    Jun 2006 Join Date
    Over Here!Location
    349Posts
    just use the one from the svn i made first clear everything in the roseon_beta database or if you dont have one just create one then execute the sql file.

  7. #7
    Member r4ptor is offline
    MemberRank
    Jun 2006 Join Date
    BrazilLocation
    25Posts
    i tried
    and look what happen


    it just dun creat nothing =/

  8. #8
    Sorcerer Supreme zad67 is offline
    Member +Rank
    Jun 2006 Join Date
    Over Here!Location
    349Posts
    ok try delecting the database roseon_beta and just execute the sql without creating the database.

  9. #9
    Member r4ptor is offline
    MemberRank
    Jun 2006 Join Date
    BrazilLocation
    25Posts
    both way dun work =/

    look XD


  10. #10
    Elite Member myripper is offline
    Member +Rank
    Aug 2006 Join Date
    ZodiacLocation
    197Posts
    Where line you insert the command ?

  11. #11
    Job Accomplished! locolijo is offline
    Grand MasterRank
    Jul 2006 Join Date
    Inside a ServerLocation
    546Posts
    Quote Originally Posted by r4ptor View Post
    i tried
    and look what happen


    it just dun creat nothing =/
    Yes, It DOESN'T work using NaviCat.. You have to import the file using phpmysql.



Advertisement