Skip to content

Commit

Permalink
docs: update GetGravity.md
Browse files Browse the repository at this point in the history
  • Loading branch information
adib-yg committed Mar 25, 2024
1 parent 1fd20e8 commit 40c8ba1
Showing 1 changed file with 21 additions and 1 deletion.
22 changes: 21 additions & 1 deletion docs/scripting/functions/GetGravity.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,32 @@ Get the currently global gravity.

## Examples

**SA-MP server:**

```c
#include <a_samp>

#if !defined GetGravity
native Float:GetGravity();
#endif

printf("Current gravity: %f", GetGravity());
public OnGameModeInit()
{
printf("Current gravity: %f", GetGravity());
return 1;
}
```

**open.mp server:**

```c
#include <open.mp>

public OnGameModeInit()
{
printf("Current gravity: %f", GetGravity());
return 1;
}
```

## Notes
Expand Down

0 comments on commit 40c8ba1

Please sign in to comment.