Skip to content

Commit

Permalink
Fix links and a few text in pages from "Basics" section
Browse files Browse the repository at this point in the history
  • Loading branch information
guilherme-gm committed Apr 14, 2024
1 parent d2324cf commit 21c4284
Show file tree
Hide file tree
Showing 10 changed files with 114 additions and 73 deletions.
26 changes: 21 additions & 5 deletions docs/basics/aid.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
An **account id** uniquely identifies a player (gender Female(F) or Male (M)) or server account (gender S) not only
inside the database, but also in inter-server communication and in associations of data with an account, such as
[account variables](../scripting/variables.md). Account ID is also used to save the character data, and is uniqu. In-game it
is mostly used as a [game id](gid). It should not be confused with [character id](cid) which
identifies a character.
# Account ID (AID)

An **account id** uniquely identifies an account, not only inside the database, but also in inter-server communication.

Accounts can be classified in 2 types, based on its "Gender":

- Player account, for accounts with gender Female (F) or Male (M)
- Server account, for accounts with gender S

For player accounts, the "Gender" information is used to determine the initial gender selection when
creating a character in-game. For old client versions, where gender selection was not possible, this was
the gender of all characters in the game account.

Account IDs are used to associate account-wide data with an account, such as:

- Characters list
- [account variables](../scripting/variables.md)

In-game it is mostly used as a [game id (GID)](./gid.md).

It should not be confused with [character id (CID)](./cid.md) which identifies a character.
17 changes: 12 additions & 5 deletions docs/basics/cid.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
A **character ID** uniquely identifies a character, not only inside the database, but also in inter-server communication
and association of data with a character, such as [character variables](../scripting/variables.md) or
[status ailments](../overview/source/status-list.md). The character ID fulfills the same role as a combination of [account ID](aid)
# Character ID (CID)

A **character ID** uniquely identifies a character, not only inside the database, but also in inter-server communication.

It associates data specific to a character, such as:

- Character name
- Character gender
- [character variables](../scripting/variables.md)
- [status ailments](../overview/source/status-list.md)

The character ID fulfills the same role as a combination of [account ID (AID)](./aid.md)
and character's slot ID, which means, if two character ids match their account IDs are automatically
the same as well.

The Character ID typically increments starting from 150000 and going up.

[Category:incomplete](Category:incomplete "wikilink")
13 changes: 8 additions & 5 deletions docs/basics/gid.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
The **GID** stands for game id or game object id. It uniquely identifies each and every dynamic object
([NPC](npc), [monster](mob "wikilink"), player, item, skill unit) inside the game. For the players a GID is
their [account id](aid), for all other objects it is a server-generated id, that changes each time the object
# Game ID (GID)

The **GID** stands for game id or game object id.

It uniquely identifies each and every dynamic object ([NPC](./npc.md), [monster](../overview/source/mob/index.md),
player, item, skill unit) inside the game.

For the players a GID is their [account id (AID)](./aid.md), for all other objects it is a server-generated id, that changes each time the object
is created.

You can view the id in-game by right-clicking on a object, when your account has enabled game master menu.

[Category:Incomplete](Category:Incomplete "wikilink")
25 changes: 15 additions & 10 deletions docs/basics/gm-commands.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,38 @@
# GM Commands

## Syntax

- `@<command>{,\<param 1\>,\<param 2\>,...}`
- `#<command>,<target>{,\<param 1\>,\<param 2\>,...}`
- `@<command> {<param 1> <param 2> ...}`
- `#<command> <target> {<param 1> <param 2> ...}`

## Description

GM commands can be used to perform a wide array of tasks in-game, such as system administration, database queries,
player actions, and collecting information regarding a player, party, guild, pet, and/or homunculus. For a full list of
atcommands, please see [`doc/atcommands.txt`](https://github.com/HerculesWS/Hercules/blob/stable/doc/atcommands.txt)
GM commands (also called atcommands because of the **@** prefix) can be used to perform a wide array of tasks in-game,
such as system administration, database queries, player actions, and collecting information regarding a player, party,
guild, pet, and/or homunculus. For a full list of atcommands,
please see [`doc/atcommands.txt`](https://github.com/HerculesWS/Hercules/blob/stable/doc/atcommands.txt)

## Examples

### atcommands

@item 909 10
```
@item 909 10
```

Entering this command in-game will give the invoking player a the item 909 (Jellopy) in the amount of 10.

### charcommands

#item Ind 909 10
```
#item Ind 909 10
```

Entering this command in-game will give the target player, Ind, the item 909 (Jellopy) in the amount of 10.

## Notes

While it is common knowledge throughout the [Ragnarok Online](Ragnarok_Online "wikilink") community that atcommands use
While it is common knowledge throughout the [Ragnarok Online](https://en.wikipedia.org/wiki/Ragnarok_Online) community that atcommands use
the **@** symbol, the symbol used can be changed to any other character by adjusting **atcommand_symbol** and
**charcommand_symbol** in
[`conf/atcommand.conf`](https://github.com/HerculesWS/Hercules/blob/stable/conf/atcommand.conf)
Expand All @@ -38,5 +45,3 @@ the **@** symbol, the symbol used can be changed to any other character by adjus
| % | party chat symbol |
| $ | guild chat symbol |
| / | client commands symbol |

[Category: Basics](Category:_Basics "wikilink")
7 changes: 3 additions & 4 deletions docs/basics/kafra.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
# Kafra

![Kafra Staff Tayelin](assets/Kafra2.gif "Kafra Staff Tayelin")

**Kafra Corporation** is a group of Ragnarok Online
[NPCs](NPC "wikilink"), which is generally responsible for setting save points, giving access to player's item storage,
[NPCs](./npc.md), which is generally responsible for setting save points, giving access to player's item storage,
providing teleport services and renting merchant class carts. Later episodes introduced two further groups for the same
services; namely Cool Event Corporation (western continent) and Cat Hand Services (new world).


[Category:Incomplete](Category:Incomplete "wikilink")
6 changes: 4 additions & 2 deletions docs/basics/mvp.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# MVP

**MVP** stands for *most valuable player*, referring to the player, which contributed most to the slay-down of a boss
monster, which is itself often referred to as MVP as well. Boss monsters are the strongest monsters in [Ragnarok
Online](Ragnarok_Online "wikilink"), from which the MVP gets extra experience and special prizes right into their
monster, which is itself often referred to as MVP as well. Boss monsters are the strongest monsters in
[Ragnarok Online](https://en.wikipedia.org/wiki/Ragnarok_Online), from which the MVP gets extra experience and special prizes right into their
inventory for defeating, aside from normal drops.
6 changes: 3 additions & 3 deletions docs/basics/npc.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
![[Kafra](Kafra "wikilink") NPC](assets/Kafra2.gif "Kafra NPC")

[NPC](NPC "wikilink") stands for Non-Player (or playable)
[NPC](./npc.md) stands for Non-Player (or playable)
Character. An NPC is any person or "living" creature in a game not controlled by a player. For example, any units in any
game that would give you a quest, tell you what to do, or just stand there while you speak to them is considered an NPC.

In [Ragnarok Online](Ragnarok_Online "wikilink"), NPCs are a pretty big part of the game. The
[Hercules](Hercules "wikilink") scripting language is used to create NPCs. You can find many premade NPCs on the
In [Ragnarok Online](https://en.wikipedia.org/wiki/Ragnarok_Online), NPCs are a pretty big part of the game. The
[Hercules](../about/index.md) scripting language is used to create NPCs. You can find many premade NPCs on the
[Hercules Boards](https://herc.ws/board/). Any character you speak to in Ragnarok Online not controlled by a player is
an NPC. From warpers, over healers and quest guides, to item sellers. Generally, in Ragnarok Online, a monster is
referred to as a [mob](../overview/source/mob/index.md), and not an NPC, however they are technically considered NPCs as well.
Expand Down
20 changes: 11 additions & 9 deletions docs/basics/rid.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,22 @@
# RID

Most scripting commands and functions will want to request data about a character, store variables referenced to that
character, send stuff to the client connected to that specific character. Whenever a script is invoked by a character,
character, send stuff to the client connected to that specific character, etc. Whenever a script is invoked by a character,
it is passed a so-called RID - this is the account ID number of a character that caused the code to execute by clicking
on it, walking into it's [OnTouch](OnTouch "wikilink") zone, or otherwise.
on it, walking into it's [OnTouch](../scripting/events/ontouch.md) zone, or otherwise.

# Usage
## Usage

When writing simple [NPCs](NPC "wikilink") only, this topic will not require much attention. However, when using
[functions](Functions "wikilink"), [timers](Timers_(Scripting) "wikilink"), or clock-based script activation, one
When writing simple [NPCs](./npc.md) only, this topic will not require much attention. However, when using
[functions](../scripting/functions.md), [timers](../scripting/timers.md), or clock-based script activation, one
requires to be aware of all cases when a script execution can be triggered without a RID attached. This will make a lot
of commands and functions unusable, since they request data from a specific character, send data to a specific client,
or store variables specific to a character, which are unavailable, if there's no RID, which refers to the character to
work with, unless [attachrid](attachrid "wikilink") is used to explicitly attach a character to the script first.
work with, unless [attachrid](../scripting/commands/attachrid.md) is used to explicitly attach a character to the script first.

Whenever is stated *invoking character* or *currently attached character*, it actually means *the character whose RID is
currently attached to the running script*. The script function [playerattached](playerattached "wikilink") can be used
Whenever is stated **invoking character** or **currently attached character**, it actually means *the character whose RID is
currently attached to the running script*. The script function [playerattached](../scripting/commands/playerattached.md) can be used
to check which is the currently attached player to the script (it will return 0 if the there is no player attached or
the attached player no longer is logged on to the map-server). The function [detachrid](detachrid "wikilink") will
the attached player no longer is logged on to the map-server). The function [detachrid](../scripting/commands//detachrid.md) will
explicitly set the RID to 0, so care must be taken, that follow-up commands do not depend on a character being attached,
especially access to [temporary character variables](../scripting/variables.md).
29 changes: 16 additions & 13 deletions docs/basics/sakray.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
**Sakray** is what official [Ragnarok Online](Ragnarok_Online "wikilink") test servers are usually referred to. They are
# Sakray

**Sakray** is what official [Ragnarok Online](https://en.wikipedia.org/wiki/Ragnarok_Online) test servers are usually referred to. They are
used to test new content and features, before they get installed on the normal servers. When the name "Sakray" is used
alone, it typically refers to the kRO Sakray server. Sakray servers are always accessible via a separate client, which
is available through a separate download.
Expand All @@ -23,20 +25,21 @@ calculation.
Schedule for tests of Renewal Server:

-  Closed Beta Test

` Start Date: 2008/07/30`
` Server Name: Sakray Renewal Test Server`
` Participation: Accepted testers`
` Test Period: 2008/07/30 ~ 2008/08/27 (4 weeks)`

```
Start Date: 2008/07/30
Server Name: Sakray Renewal Test Server
Participation: Accepted testers
Test Period: 2008/07/30 ~ 2008/08/27 (4 weeks)
```
-  Open Beta Test

` Start Date: 2008/08/27`
` Server Name: Sakray Renewal Test Server`
` Participation: Anyone`
` Test Period: 2008/08/27 ~ 2008/09/24 (4 weeks)`
```
Start Date: 2008/08/27
Server Name: Sakray Renewal Test Server
Participation: Anyone
Test Period: 2008/08/27 ~ 2008/09/24 (4 weeks)
```

## Usage

[Hexed](Hexing "wikilink") kRO Sakray clients are the most used clients with [Hercules](Hercules "wikilink"), although a
[Hexed](../client/hexing.md) kRO Sakray clients are the most used clients with [Hercules](../about/index.md), although a
few people prefer using kRO (live server) clients or clients from different service providers.
38 changes: 21 additions & 17 deletions docs/basics/zeny.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
[Zeny](Zeny "wikilink") is the in-game currency used in [Ragnarok Online](Ragnarok_Online "wikilink"), which can be used
for buying and selling items from and to [NPC](NPC "wikilink") shops and other players.
# Zeny

Zeny is the in-game currency used in [Ragnarok Online](https://en.wikipedia.org/wiki/Ragnarok_Online), which can be used
for buying and selling items from and to [NPC](./npc.md) shops and other players.

## Limitation

The technical limit is for both the client and server up to 2,147,483,647 Zeny, which is typically capped at
1,000,000,000. The cap can be changed inside
[`src/common/mmo.h`](https://github.com/HerculesWS/Hercules/blob/stable/src/common/mmo.h) by adjusting the macro
*MAX_ZENY* to a desired value below the technical limit. The source must be recompiled after this change. If a value is
`MAX_ZENY` to a desired value below the technical limit. The source must be recompiled after this change. If a value is
specified which surpasses the technical limit, the server will not compile.

## Penalty
Expand All @@ -21,26 +23,28 @@ amount of Zeny the player holds upon death:
zeny_penalty: 0
```

[Mapflags](Mapflag "wikilink") can be set on certain maps to disable the zeny penalty in
[`conf/mapflag/nopenalty.txt`](https://github.com/HerculesWS/Hercules/blob/stable/conf/mapflag/nopenalty.txt)
[Mapflags](../scripting/mapflag.md) can be set on certain maps to disable the zeny penalty in
[`npc/mapflag/nopenalty.txt`](https://github.com/HerculesWS/Hercules/blob/stable/npc/mapflag/nopenalty.txt)

## Vending

The amount of Zeny that can be set to an item when vending is soft-limited to 1,000,000,000 and can be overridden by the
setting *vending_max_value* in
[`conf/battle/items.conf`](https://github.com/HerculesWS/Hercules/blob/stable/conf/battle/items.conf) and
[hexing](hexing "wikilink") the client to correct the client-side warnings.
setting `vending_max_value` in
[`conf/map/battle/items.conf`](https://github.com/HerculesWS/Hercules/blob/stable/conf/map/battle/items.conf) and
[hexing](../client/hexing.md) the client to correct the client-side warnings.

If the seller obtains more Zeny through vending than *MAX_ZENY* the surplus Zeny is discarded. To avoid this, the
setting *vending_over_max* in
[`conf/battle/items.conf`](https://github.com/HerculesWS/Hercules/blob/stable/conf/battle/items.conf) can be set to
*no*, which causes the deal to fail if it would result in more Zeny than the seller is able to hold.
If the seller obtains more Zeny through vending than `MAX_ZENY` the surplus Zeny is discarded. To avoid this, the
setting `vending_over_max` in
[`conf/map/battle/items.conf`](https://github.com/HerculesWS/Hercules/blob/stable/conf/map/battle/items.conf) can be set to
`false`, which causes the deal to fail if it would result in more Zeny than the seller is able to hold.

## Scripting

The name *Zeny* is recognized by the script engine as a [parameter constant](parameter_constant "wikilink"), which
affects the amount of Zeny of the [currently attached](RID#Usage "wikilink") player. It can be both read and written.
The name `Zeny` is recognized by the script engine as a [parameter constant](../scripting/parameter-constant.md), which
affects the amount of Zeny of the [currently attached](./rid.md#usage) player. It can be both read and written.

[`set`](set "wikilink")` Zeny,Zeny+120;  // gives the player 120z`
[`mes`](mes "wikilink")` "Your current balance is "+Zeny+"z.";`
[`set`](set "wikilink")` Zeny,0;  // takes all Zeny from the player`
```C
Zeny += 120; // gives the player 120z
mesf("Your current balance is %dz.", Zeny);
Zeny = 0; // takes all Zeny from the player
```

0 comments on commit 21c4284

Please sign in to comment.