Jump to content
  • 0

pass through a cell buff or with pop up mes


Gouki

Question


  • Group:  Members
  • Topic Count:  82
  • Topics Per Day:  0.06
  • Content Count:  241
  • Reputation:   11
  • Joined:  08/12/20
  • Last Seen:  

Hi,

Map Ex. new_1-1 (on the bridge part)

when a new character passes the middle part of the bridge (or a certain cell) he will get an automatic buff, and newbie items.
prolly a Mes also to welcome the player.

basically the point is to let every newbie player receive the freebies and extra buff.

Link to comment
Share on other sites

12 answers to this question

Recommended Posts

  • 0

  • Group:  Members
  • Topic Count:  61
  • Topics Per Day:  0.02
  • Content Count:  911
  • Reputation:   166
  • Joined:  11/27/14
  • Last Seen:  

prontera,0,0,3	script	TouchMe	-1,{

OnTouch:
		getitem 7227,1;
		dispbottom "You just receive an item from GameMaster Team";

}

Not tested just made this from phone

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  0
  • Topics Per Day:  0
  • Content Count:  5
  • Reputation:   1
  • Joined:  11/24/19
  • Last Seen:  

13 minutes ago, Poring King said:

prontera,0,0,3	script	TouchMe	-1,{

OnTouch:
		getitem 7227,1;
		dispbottom "You just receive an item from GameMaster Team";

}

Not tested just made this from phone

This will give away the item everytime though.

You will probably want to add a check to avoid that. I would go with making one of the given items transaction restricted so it is always being carried and can look for it like this:

if(countitem(7227)==0) getitem 7227,1;

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  82
  • Topics Per Day:  0.06
  • Content Count:  241
  • Reputation:   11
  • Joined:  08/12/20
  • Last Seen:  

@Poring King I modified your script, not sure if this script means once per account only. correct if I'm wrong thank you!
 

prontera,0,0,3	script	TouchMe	-1,{

OnTouch:
		if(#newbie != 0){
		getitem 7227,1;
		set #newbie,1;
		mes "[Ragnarok Online]";
		mes "Welcome to Ragnarok Online!";
		}else{
		mes "[Ragnarok Online]";
		mes "Welcome to Ragnarok Online!";
		}
}

 

If I add coordinates, to the X and Y of Prontera, would that mean if a character passed through that cell this will be triggered? If that's not it, the initial plan would be like a checkpoint if they passed through those or that cell the script will be triggered. I think the initial script is if the player lands on a certain map?

prontera,0,0,3	script	TouchMe	-1,{
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  61
  • Topics Per Day:  0.02
  • Content Count:  911
  • Reputation:   166
  • Joined:  11/27/14
  • Last Seen:  

8 minutes ago, Almond Snicker said:

@Poring King I modified your script, not sure if this script means once per account only. correct if I'm wrong thank you!
 


prontera,0,0,3	script	TouchMe	-1,{

OnTouch:
		if(#newbie != 0){
		getitem 7227,1;
		set #newbie,1;
		mes "[Ragnarok Online]";
		mes "Welcome to Ragnarok Online!";
		}else{
		mes "[Ragnarok Online]";
		mes "Welcome to Ragnarok Online!";
		}
}

 

If I add coordinates, to the X and Y of Prontera, would that mean if a character passed through that cell this will be triggered? If that's not it, the initial plan would be like a checkpoint if they passed through those or that cell the script will be triggered. I think the initial script is if the player lands on a certain map?


prontera,0,0,3	script	TouchMe	-1,{

If you want to make it 1 free per account add this
 
 

If (#newbie == 1) goto SorryMessage;



SorryMessage:
              mes "[ Newbie ]";
              mes "You already took your freebies!";
              mes "Have fun in ^E066FFSEARO!^000000";
              close;

 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  61
  • Topics Per Day:  0.02
  • Content Count:  911
  • Reputation:   166
  • Joined:  11/27/14
  • Last Seen:  

You can also add a different tweek you can use on
 

-    script    freebies    -1,{

OnPCLoginEvent:
				if( #newbie == 1) end;
				set #newbie,1;
				getitem 7227,1;
				dispbottom "Welcome to our server!";
				end;
}

 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  82
  • Topics Per Day:  0.06
  • Content Count:  241
  • Reputation:   11
  • Joined:  08/12/20
  • Last Seen:  

8 minutes ago, Poring King said:

You can also add a different tweek you can use on
 


-    script    freebies    -1,{

OnPCLoginEvent:
				if( #newbie == 1) end;
				set #newbie,1;
				getitem 7227,1;
				dispbottom "Welcome to our server!";
				end;
}

 

This is definitely an option, thanks!

But, how about the script triggers whenever you cross a certain cell? do you happen to know how others do that? 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  0
  • Topics Per Day:  0
  • Content Count:  5
  • Reputation:   1
  • Joined:  11/24/19
  • Last Seen:  

4 hours ago, Almond Snicker said:

This is definitely an option, thanks!

But, how about the script triggers whenever you cross a certain cell? do you happen to know how others do that? 

From the documentation, pasted only parts referring to the discussed topic:

<map name>,<x>,<y>,<facing>%TAB%script%TAB%<NPC Name>%TAB%<sprite id>,<triggerX>,<triggerY>,{<code>}

A '-1' Sprite ID will make the NPC invisible (and unclickable).

TriggerX and triggerY, if given, will define an area, centered on NPC and
spanning triggerX cells in every direction across X and triggerY in every
direction across Y. Walking into that area will trigger the NPC. If no
'OnTouch:' special label is present in the NPC code, the execution will start
from the beginning of the script, otherwise, it will start from the 'OnTouch:'
label. Monsters can also trigger the NPC, though the label 'OnTouchNPC:' is
used in this case.

Thus, taking @Poring King's first example, you would declare the NPC like this I think

prontera,0,0,3	script	TouchMe	-1,11,11{
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  82
  • Topics Per Day:  0.06
  • Content Count:  241
  • Reputation:   11
  • Joined:  08/12/20
  • Last Seen:  

9 minutes ago, Penicilina said:

From the documentation, pasted only parts referring to the discussed topic:

<map name>,<x>,<y>,<facing>%TAB%script%TAB%<NPC Name>%TAB%<sprite id>,<triggerX>,<triggerY>,{<code>}

A '-1' Sprite ID will make the NPC invisible (and unclickable).

TriggerX and triggerY, if given, will define an area, centered on NPC and
spanning triggerX cells in every direction across X and triggerY in every
direction across Y. Walking into that area will trigger the NPC. If no
'OnTouch:' special label is present in the NPC code, the execution will start
from the beginning of the script, otherwise, it will start from the 'OnTouch:'
label. Monsters can also trigger the NPC, though the label 'OnTouchNPC:' is
used in this case.

Thus, taking @Poring King's first example, you would declare the NPC like this I think


prontera,0,0,3	script	TouchMe	-1,11,11{

hmm, alright I'll try this out later on, understanding OnTouch over OnTouchNPC is that Monsters can't touch, OnTouchNPC, is that right?

will update later how it goes..

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  61
  • Topics Per Day:  0.02
  • Content Count:  911
  • Reputation:   166
  • Joined:  11/27/14
  • Last Seen:  

Yes i forgot to add

 

prontera,0,03	script	TouchMe -1,10,10{

The 10,10 from the -1,10,10{

Make the NPC Touchable around by 10x10 area from the NPC

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  14
  • Topics Per Day:  0.01
  • Content Count:  52
  • Reputation:   0
  • Joined:  07/14/17
  • Last Seen:  

6 hours ago, Poring King said:

Yes i forgot to add

 


prontera,0,03	script	TouchMe -1,10,10{

The 10,10 from the -1,10,10{

Make the NPC Touchable around by 10x10 area from the NPC

ahhh hmm,, does that mean you could only touch the npc if you are within 10,10 cell radius of the npc?

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  61
  • Topics Per Day:  0.02
  • Content Count:  911
  • Reputation:   166
  • Joined:  11/27/14
  • Last Seen:  

On 8/14/2020 at 1:45 PM, kevinyrchua said:

ahhh hmm,, does that mean you could only touch the npc if you are within 10,10 cell radius of the npc?

Yes you are right!

 

On 8/15/2020 at 10:31 PM, Almond Snicker said:

new_1-1,133,113, 3	script	Welcome to RO	811,3,20,{
end; // If you don't like that NPC can't be clicked.
OnTouch:
				if( #newbie == 1) end;
				set #newbie,1;
				getitem 30000,1;
				getitem 30001,1;
				getitem 30002,1;
				getitem 30003,1;
				getitem 30004,1;
				getitem 30114,1;
				rentitem 20512,604800;
				sc_start SC_BLESSING,10000,10;	 specialeffect2 EF_BLESSING;
				sc_start SC_INCREASEAGI,10000,10;  specialeffect2 EF_INCAGILITY;
				mes "[RO]";
				mes "Welcome to RO!";
				mes "Here's your one time free newbie set.";
				mes "RoK on!";
				end;
OnInit:
set .message$, "WELCOME TO RO!     ";

while (1) {
	set .message$, delchar(.message$+charat(.message$,0),0);
	delwaitingroom;
	waitingroom .message$, 0;
	sleep 200;
}
}

Here's the final script that I've merged, thank you so much @Poring King

Ok

Link to comment
Share on other sites

  • -1

  • Group:  Members
  • Topic Count:  82
  • Topics Per Day:  0.06
  • Content Count:  241
  • Reputation:   11
  • Joined:  08/12/20
  • Last Seen:  

new_1-1,133,113, 3	script	Welcome to RO	811,3,20,{
end; // If you don't like that NPC can't be clicked.
OnTouch:
				if( #newbie == 1) end;
				set #newbie,1;
				getitem 30000,1;
				getitem 30001,1;
				getitem 30002,1;
				getitem 30003,1;
				getitem 30004,1;
				getitem 30114,1;
				rentitem 20512,604800;
				sc_start SC_BLESSING,10000,10;	 specialeffect2 EF_BLESSING;
				sc_start SC_INCREASEAGI,10000,10;  specialeffect2 EF_INCAGILITY;
				mes "[RO]";
				mes "Welcome to RO!";
				mes "Here's your one time free newbie set.";
				mes "RoK on!";
				end;
OnInit:
set .message$, "WELCOME TO RO!     ";

while (1) {
	set .message$, delchar(.message$+charat(.message$,0),0);
	delwaitingroom;
	waitingroom .message$, 0;
	sleep 200;
}
}

Here's the final script that I've merged, thank you so much @Poring King

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...