Jump to content

louigui0224

Members
  • Posts

    139
  • Joined

  • Last visited

Profile Information

  • Gender
    Male
  • Location
    philippines, Cavite
  • Server
    Freelance
  • Github: Paradox214

Recent Profile Visitors

1,147 profile views

louigui0224's Achievements

  1. Hello good day guys, I'm currently using a slotmachine NPC and I just returned to creating RO after 4years and still trying to remember things I have before but for now I need your help. I wanted to know if how can I put like a rarity on the rewards on the triple slot machine. For example first reward is TCG with 100% of chance then 2nd Poring coin with only 50% chance to receive, 3rd donation coin with 10% chance to receive. TIA. Here is the script: /* ============================================================= /* Slot Machine - Triple Slot Machine /* ============================================================= /* Version: v0.7 /* v0.1 - Original Script Created. /* v0.2 - Added Option for Triple Slot Machine with animations. /* v0.3 - Added support for item pricing &/or zeny pricing. /* v0.4 - Cleaned up script variables for easy editing. /* v0.5 - Tested out some new scripting methods with IF(THEN). /* v0.6 - Added option to change slot machine modes ingame. /* v0.7 - Added optional sound effects to slot machines. - NOTE /* ============================================================= /* Description /* ============================================================= /* This script will allow users to spend zeny &/or an item for a /* chance to win a prize from the slot machine. Currently there /* are 2 versions. First is a Single Slot Machine, where only 1 /* slot is rolled. Second is the Triple Slot machine, where 3 /* slots are rolled. For either version, SUCCESS must be the /* only thing displayed in order to win. /* ============================================================= /* NOTE - If using soundeffects you must add the ".wav" files /* provided in the ".rar" file to your: data/wav folder located /* in either your: ( Ragnarok folder ) OR ( .grf file ) /* ============================================================= /* Created By: GmOcean /* ===========================================================*/ prontera,152,176,4 script SlotMachine::1slot 563,{ if( getgmlevel() == 99 ) { mes "Welcome Administrator.","What would you like to do?"; menu "Play Game",-,"Change Slot Machine Mode",iMode; next; } switch( getd(".mode"+strnpcinfo(3)+"") ){ case 0: // Single Slot machine mode. mes "Do you want to play a game?"; if( !.payment ) { mes "It costs: "+ .ssm_payment_message$[0] +" to play."; } else if ( .payment == 1 ) { mes "It costs: "+ .ssm_payment_message$[1] +" to play."; } else if ( .payment == 2 ) { mes "It costs: "+ .ssm_payment_message$[0] +" & "+ .payment_message$[1] +" to play."; } if( select("YES:NO") == 2 || Zeny < .ssm_payment[0] && ( !.payment || .payment == 2 ) || countitem(.ssm_payment[1]) < .ssm_payment[2] && .payment ){ close; } while( @menu == 1 ){ if( !.payment || .payment == 2 ) { Zeny -= .ssm_payment[0]; } if( .payment ) { delitem( .ssm_payment[1], .ssm_payment[2] ); } if( .soundeffects ) { soundeffect "se_cash_provider.wav",0; } [email protected] = rand(1,100); if( [email protected] < atoi(.ssm_animate$[0]) ){ [email protected] = 1; } else { [email protected] = 2; } [email protected] = 1; while( [email protected] < atoi(.ssm_animate$[[email protected]]) ) { cutin .ssm_animate$[3] + [email protected],4; sleep2 ( ( atoi(.ssm_animate$[4]) * 1000 ) / atoi(.ssm_animate$[[email protected]]) ); [email protected]++; } if( [email protected] == 1 ){ cutin .ssm_animate$[3] + atoi(.ssm_animate$[[email protected]]),4; dispbottom "Failed"; } else { cutin .ssm_animate$[3] + atoi(.ssm_animate$[[email protected]]),4; if( !.prize || .prize == 2 ) { Zeny += .ssm_prize[0]; } if( .prize ) { getitem .ssm_prize[1], .ssm_prize[2]; } if( .soundeffects ){ soundeffect "rog_steal coin.wav",0; } } if( select("Another Round:I'm done") == 2 || Zeny < .ssm_payment[0] && ( !.payment || .payment == 2 ) || countitem(.ssm_payment[1]) < .ssm_payment[2] && .payment ){ cutin "",255; close; } } end; case 1: // Triple Slot machine mode. mes "Do you want to play a game?"; if( !.payment ) { mes "It costs: "+ .tsm_payment_message$[0] +" to play."; } else if ( .payment == 1 ) { mes "It costs: "+ .tsm_payment_message$[1] +" to play."; } else if ( .payment == 2 ) { mes "It costs: "+ .tsm_payment_message$[0] +" & "+ .tsm_payment_message$[1] +" to play."; } if( select("YES:NO") == 2 || Zeny < .tsm_payment[0] && ( !.payment || .payment == 2 ) || countitem(.tsm_payment[1]) < .tsm_payment[2] && .payment ){ close; } while( @menu == 1 ){ if( !.payment || .payment == 2 ) { Zeny -= .tsm_payment[0]; } if( .payment ) { delitem( .tsm_payment[1], .tsm_payment[2] ); } if( .soundeffects ) { soundeffect "se_cash_provider.wav",0; } // Slot 1 = 100% Chance for success. (Because I didn't make a fail animation for it. [email protected] = rand(1,100); //Rolls dice for Slot 2 [email protected] = rand(1,100); //Rolls dice for Slot 3 if( [email protected] <= atoi(.tsm_animate$[0]) && [email protected] <= atoi(.tsm_animate$[1]) ){ [email protected] = 8; } else if( [email protected] <= atoi(.tsm_animate$[0]) && [email protected] > atoi(.tsm_animate$[1]) ){ [email protected] = 6; } else if( [email protected] > atoi(.tsm_animate$[0]) && [email protected] <= atoi(.tsm_animate$[1]) ){ [email protected] = 4; } else { [email protected] = 2; } [email protected] = 1; while( [email protected] < atoi(.tsm_animate$[[email protected]+1]) ) { cutin .tsm_animate$[[email protected]] + [email protected],4; sleep2 ( ( atoi(.tsm_animate$[10]) * 1000 ) / atoi(.tsm_animate$[[email protected]+1]) ); [email protected]++; } cutin .tsm_animate$[[email protected]] + atoi(.tsm_animate$[[email protected]+1]),4; if( [email protected] == 2 ){ if( !.prize || .prize == 2 ) { Zeny += .tsm_prize[0]; } if( .prize ) { getitem .tsm_prize[1], .tsm_prize[2]; } if( .soundeffects ){ soundeffect "rog_steal_coin.wav",1; } } else { dispbottom "Failed"; } if( select("Another Round:I'm done") == 2 || Zeny < .tsm_payment[0] && ( !.payment || .payment == 2 ) || countitem(.tsm_payment[1]) < .tsm_payment[2] && .payment ){ cutin "",255; close; } } end; } OnSingleSlot: setd ".mode"+strnpcinfo(3)+"",0; end; OnTripleSlot: setd ".mode"+strnpcinfo(3)+"",1; end; iMode: next; mes "Which did you want to do?"; menu "Change THIS machine's mode:Change ALL machine's mode",-; if( @menu == 1 ) { next; mes "What mode would you like this machine to have?"; menu "Single Slot Machine Mode:Triple Slot Machine Mode",-; if( @menu == 1 ) { setd ".mode"+strnpcinfo(3)+"",0; } else { setd ".mode"+strnpcinfo(3)+"",1; } close; } else { next; mes "What mode would you like to change all slot machines to?"; menu "Single Slot Machine Mode:Triple Slot Machine Mode",-; if( @menu == 1 ) { donpcevent "::OnSingleSlot"; } else { donpcevent "::OnTripleSlot"; } close; } OnInit: // 0 = Disabled, 1 = Enabled. .soundeffects = 1; //[ 0 = Single Slot Machine Mode ]_[ 1 = Triple Slot Machine Mode ] setd ".mode"+strnpcinfo(3)+"",0; //[0] = Fail Rate //[1] = Fail (Do not change) //[2] = Success (Do not change) //[3] = File Name (Do not change) //[4] = Animation Time (Do not change, for best results ) setarray .ssm_animate$[0],"30","29","33","slot_","3"; //[0] = Fail Rate "Slot 2" //[1] = Fail Rate "Slot 3" //[2] = SSS (Do not change) //[3] = SSS_Count (Do not change) //[4] = SSF (Do not change) //[5] = SSF_Count (Do not change) //[6] = SFS (Do not change) //[7] = SFS_Count (Do not change) //[8] = SFF (Do not change) //[9] = SFF_Count (Do not change) //[10] = Animation Time (Do not change, for best results ) setarray .tsm_animate$[0],"30","30","SSS_","41","SSF_","37","SFS_","41","SFF_","45","3"; // Prize Settings // Prize Type // 0 = Zeny, 1 = Item, 2 = Zeny&Item .prize = 2; // [0] = Zeny, [1] = Item ID, [2] = Item Amount; setarray .ssm_prize[0],125,501,10; setarray .tsm_prize[0],450,501,30; // Payment Settings // Payment Type // 0 = Zeny, 1 = Item, 2 = Zeny&Item .payment = 2; // [0] = Zeny, [1] = Item ID, [2] = Item Amount; setarray .ssm_payment[0],100,501,1; // Single Slot Machine Payment Price setarray .tsm_payment[0],300,501,3; // Triple Slot Machine Payment Price // DO NOT CHANGE BELOW // Payment Text Syntax setarray .ssm_payment_message$[0],""+ .ssm_payment[0] +" zeny",""+ getitemname(.ssm_payment[1]) +" x"+ .ssm_payment[2] +""; setarray .tsm_payment_message$[0],""+ .tsm_payment[0] +" zeny",""+ getitemname(.tsm_payment[1]) +" x"+ .tsm_payment[2] +""; end; } //Duplicates prontera,154,176,4 duplicate(1slot) SlotMachine#2slot 563 prontera,156,176,4 duplicate(1slot) SlotMachine#3slot 563 Here is the line: // Prize Settings // Prize Type // 0 = Zeny, 1 = Item, 2 = Zeny&Item .prize = 2; // [0] = Zeny, [1] = Item ID, [2] = Item Amount; setarray .ssm_prize[0],125,1161,30,501,1; setarray .tsm_prize[0],450,1161,30,501,1;
  2. Hello guys, may I request for job_exp.txt which can support upto lvl 750? I tried to follow the guide but I was unable to reach level 750 and 1st transcedent jobs are stuck to lvl 0 and can't go higher. please. Thanks.
  3. Hi @Technoken thank you so much for your reply but the thing is im having an error while compiling already followed everything... check this image.
  4. I just did a git clone to the rathena in github but how can i set it up without the rathena 10 sln? i already tried to do it again..i just received same result in tortoise svn.
  5. Hi guys...i already ask for emistry to help me with this script and it was successful but now my problem is i dont know how to put in the script that when the script is activated thats the time when the monster will summon in the map and when the npc will off it will remove all the monster and also kick the players in the map...here is the script. prontera,156,165,4 script Coupon Farmer 436,{ mes "[Quest]"; mes callfunc("F_Hi"); mes "I can warp you to the jungle coupon."; next; menu "Yes, Warp me",-,"Leave",M_EXIT; mes "[Quest]"; mes "Okay all i need to have is just"; next; mes "[Quest]"; mes "1 million of zeny"; next; mes "[Quest]"; mes "Do you have all the item?"; next; menu "Yes",-,"No",M_EXIT; if (Zeny < 1000000) GOTO L_NOITEM; set Zeny,Zeny-1000000; warp "moc_ruins" ,0,0; mes "[Quest]"; mes "Thank you very much!"; mes callfunc("F_Bye"); close; L_NOITEM: mes "[Quest]"; mes "Sorry you don't have zeny."; emotion e_sry; close; M_EXIT: mes "[Quest]"; mes callfunc("F_Bye"); close; OnInit: waitingroom "Donation Farmzone 2 Hours",0; OnMinute00: if (( gettime(DT_DAYOFWEEK) == SATURDAY || gettime(DT_DAYOFWEEK) == SUNDAY ) && (( gettime(DT_HOUR) >= 11 && gettime(DT_HOUR) < 12 ) || ( gettime(DT_HOUR) >= 18 && gettime(DT_HOUR) < 19 )) ) { enablenpc strnpcinfo(3); } else { disablenpc strnpcinfo(3); } end;
  6. my server already running for 2 months and i just noticed now that my server doesnt have @adjgmlvl...
  7. I dont understand how to edit those codes you sent..but actually my plan for the time is going to be 11am to 12pm and 6pm-8pm sat sunday.
  8. but there is no time to the one that you edit sir @Emistry
  9. already did it but its not working.here is the script. prontera,156,165,4 script Coupon Farmer 436,{ OnHour11: OnHour18: If(gettime(DT_DAYOFWEEK) == SATURDAY || gettime(DT_DAYOFWEEK) == SUNDAY) enablenpc "Coupon Farmer"; end; OnHour12: OnHour19: If(gettime(DT_DAYOFWEEK) == SATURDAY || gettime(DT_DAYOFWEEK) == SUNDAY) disablenpc "Coupon Farmer"; end; mes "[Quest]"; mes callfunc("F_Hi"); mes "I can warp you to the jungle coupon."; next; menu "Yes, Warp me",-,"Leave",M_EXIT; mes "[Quest]"; mes "Okay all i need to have is just"; next; mes "[Quest]"; mes "1 million of zeny"; next; mes "[Quest]"; mes "Do you have all the item?"; next; menu "Yes",-,"No",M_EXIT; if (Zeny < 1000000) GOTO L_NOITEM; set Zeny,Zeny-1000000; warp "moc_ruins" ,0,0; mes "[Quest]"; mes "Thank you very much!"; mes callfunc("F_Bye"); close; L_NOITEM: mes "[Quest]"; mes "Sorry you don't have zeny."; emotion e_sry; close; M_EXIT: mes "[Quest]"; mes callfunc("F_Bye"); close; OnInit: waitingroom "Donation Farmzone 2 Hours",0; end; }
  10. where should i add this sir??inside the script(in which part should i add this code?) or do i need to create another .txt and load it?
  11. I\m trying to edit the npc but i dont know how to put the schedule to this npc...i want this npc to show every weekends..by 11am-1pm and after 1pm it will hide and will show again by 6pm-8pm sat sun...is that possible? //===== eAthena Script ======================================= //= Quests: Archangel Wings, Archdemon Wings, Deviling Wings, Little Angel Wings //============================================================ prontera,156,165,4 script Coupon Farmer 436,{ mes "[Quest]"; mes callfunc("F_Hi"); mes "I can warp you to the jungle coupon."; next; menu "Yes, Warp me",-,"Leave",M_EXIT; mes "[Quest]"; mes "Okay all i need to have is just"; next; mes "[Quest]"; mes "1 million of zeny"; next; mes "[Quest]"; mes "Do you have all the item?"; next; menu "Yes",-,"No",M_EXIT; if (Zeny < 1000000) GOTO L_NOITEM; set Zeny,Zeny-1000000; warp "moc_ruins" ,0,0; mes "[Quest]"; mes "Thank you very much!"; mes callfunc("F_Bye"); close; L_NOITEM: mes "[Quest]"; mes "Sorry you don't have zeny."; emotion e_sry; close; M_EXIT: mes "[Quest]"; mes callfunc("F_Bye"); close; OnInit: waitingroom "Donation Farmzone 2 Hours",0; end; }
  12. any chance to do this to hollgrehen refiner? failure, the equipment is not destroyed; rather, its refine level decreases by 1
  13. This is what i put...and it says 0 row affected...and when i tried to search there are still +20 items in the inventory...and when i logged ingame the items still hase refines. UPDATE inventory INNER JOIN item_db ON inventory.nameid = item_db.id SET inventory.refine=0 WHERE item_db.type IN (256,32,2,1,64,16,512); Bump. already done i type just a very simple code.. UPDATE inventory SET inventory.refine=0 UPDATE cart_inventory SET cart_inventory.refine=0 UPDATE storage SET storage.refine=0
  14. so before changing eerything. UPDATE inventory INNER JOIN item_db_re ON inventory.nameid = item_db_re.id(So just change item_db_re to item_db_pre?) and everything is ok beside from changing the cartinventory and storage? SET inventory.refine=0 WHERE item_db_re.type IN ({4);
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.