Skip to content

Commit 1ea7eb9

Browse files
committed
Merge branch 'feat/docker' of https://github.com/habecker/PySAMP into feat/docker
2 parents f25d620 + 89ce724 commit 1ea7eb9

File tree

398 files changed

+179143
-3
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

398 files changed

+179143
-3
lines changed
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

scripts/functions/callbacks.txt

Whitespace-only changes.

scripts/functions/functions.txt

Lines changed: 394 additions & 0 deletions
Large diffs are not rendered by default.

scripts/idl/a_actor.idl

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
/* Copyright (C) 2011-2015 Zeex
2+
*
3+
* Licensed under the Apache License, Version 2.0 (the "License");
4+
* you may not use this file except in compliance with the License.
5+
* You may obtain a copy of the License at
6+
*
7+
* http://www.apache.org/licenses/LICENSE-2.0
8+
*
9+
* Unless required by applicable law or agreed to in writing, software
10+
* distributed under the License is distributed on an "AS IS" BASIS,
11+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
* See the License for the specific language governing permissions and
13+
* limitations under the License.
14+
*/
15+
16+
[native] int CreateActor(int modelid, float x, float y, float z, float rotation);
17+
[native] bool DestroyActor(int actorid);
18+
[native] bool IsActorStreamedIn(int actorid, int forplayerid);
19+
20+
[native] bool SetActorVirtualWorld(int actorid, int vworld);
21+
[native] int GetActorVirtualWorld(int actorid);
22+
23+
[native] bool ApplyActorAnimation(int actorid, string animlib, string animname, float fDelta, bool loop, bool lockx, bool locky, bool freeze, int time);
24+
[native] bool ClearActorAnimations(int actorid);
25+
26+
[native] bool SetActorPos(int actorid, float x, float y, float z);
27+
[native] bool GetActorPos(int actorid, [out] float x, [out] float y, [out] float z);
28+
[native] bool SetActorFacingAngle(int actorid, float angle);
29+
[native] bool GetActorFacingAngle(int actorid, [out] float angle);
30+
31+
[native] bool SetActorHealth(int actorid, float health);
32+
[native] bool GetActorHealth(int actorid, [out] float health);
33+
[native] bool SetActorInvulnerable(int actorid, bool invulnerable = true);
34+
[native] bool IsActorInvulnerable(int actorid);
35+
36+
[native] bool IsValidActor(int actorid);

scripts/idl/a_http.idl

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
/* Copyright (C) 2013-2015 Zeex
2+
*
3+
* Licensed under the Apache License, Version 2.0 (the "License");
4+
* you may not use this file except in compliance with the License.
5+
* You may obtain a copy of the License at
6+
*
7+
* http://www.apache.org/licenses/LICENSE-2.0
8+
*
9+
* Unless required by applicable law or agreed to in writing, software
10+
* distributed under the License is distributed on an "AS IS" BASIS,
11+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
* See the License for the specific language governing permissions and
13+
* limitations under the License.
14+
*/
15+
16+
const int HTTP_GET = 1;
17+
const int HTTP_POST = 2;
18+
const int HTTP_HEAD = 3;
19+
20+
const int HTTP_ERROR_BAD_HOST = 1;
21+
const int HTTP_ERROR_NO_SOCKET = 2;
22+
const int HTTP_ERROR_CANT_CONNECT = 3;
23+
const int HTTP_ERROR_CANT_WRITE = 4;
24+
const int HTTP_ERROR_CONTENT_TOO_BIG = 5;
25+
const int HTTP_ERROR_MALFORMED_RESPONSE = 6;
26+
27+
[native] bool HTTP(int index,
28+
int type,
29+
string url,
30+
string data,
31+
[in, bind("OnHTTPResponse")] string callback);
32+
33+
[callback, nonstandard] void OnHTTPResponse(int index,
34+
int response_code,
35+
string data);

scripts/idl/a_objects.idl

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
/* Copyright (C) 2011-2015 Zeex
2+
*
3+
* Licensed under the Apache License, Version 2.0 (the "License");
4+
* you may not use this file except in compliance with the License.
5+
* You may obtain a copy of the License at
6+
*
7+
* http://www.apache.org/licenses/LICENSE-2.0
8+
*
9+
* Unless required by applicable law or agreed to in writing, software
10+
* distributed under the License is distributed on an "AS IS" BASIS,
11+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
* See the License for the specific language governing permissions and
13+
* limitations under the License.
14+
*/
15+
16+
[native] int CreateObject(int modelid, float x, float y, float z, float rX, float rY, float rZ, float DrawDistance = 0.0);
17+
[native] bool AttachObjectToVehicle(int objectid, int vehicleid, float fOffsetX, float fOffsetY, float fOffsetZ, float fRotX, float fRotY, float fRotZ);
18+
[native] bool AttachObjectToObject(int objectid, int attachtoid, float fOffsetX, float fOffsetY, float fOffsetZ, float fRotX, float fRotY, float fRotZ, bool SyncRotation = false);
19+
[native] bool AttachObjectToPlayer(int objectid, int playerid, float fOffsetX, float fOffsetY, float fOffsetZ, float fRotX, float fRotY, float fRotZ);
20+
[native] bool SetObjectPos(int objectid, float x, float y, float z);
21+
[native] bool GetObjectPos(int objectid, [out] float x, [out] float y, [out] float z);
22+
[native] bool SetObjectRot(int objectid, float rotX, float rotY, float rotZ);
23+
[native] bool GetObjectRot(int objectid, [out] float rotX, [out] float rotY, [out] float rotZ);
24+
[native] int GetObjectModel(int objectid);
25+
[native] bool SetObjectNoCameraCol(int objectid);
26+
[native] bool IsValidObject(int objectid);
27+
[native] bool DestroyObject(int objectid);
28+
[native] int MoveObject(int objectid, float X, float Y, float Z, float Speed, float RotX = -1000.0, float RotY = -1000.0, float RotZ = -1000.0);
29+
[native] bool StopObject(int objectid);
30+
[native] bool IsObjectMoving(int objectid);
31+
[native] bool EditObject(int playerid, int objectid);
32+
[native] bool EditPlayerObject(int playerid, int objectid);
33+
[native] bool SelectObject(int playerid);
34+
[native] bool CancelEdit(int playerid);
35+
[native] int CreatePlayerObject(int playerid, int modelid, float x, float y, float z, float rX, float rY, float rZ, float DrawDistance = 0.0);
36+
[native] bool AttachPlayerObjectToPlayer(int objectplayer, int objectid, int attachplayer, float OffsetX, float OffsetY, float OffsetZ, float rX, float rY, float rZ);
37+
[native] bool AttachPlayerObjectToVehicle(int playerid, int objectid, int vehicleid, float fOffsetX, float fOffsetY, float fOffsetZ, float fRotX, float fRotY, float RotZ);
38+
[native] bool SetPlayerObjectPos(int playerid, int objectid, float x, float y, float z);
39+
[native] bool GetPlayerObjectPos(int playerid, int objectid, [out] float x, [out] float y, [out] float z);
40+
[native] bool SetPlayerObjectRot(int playerid, int objectid, float rotX, float rotY, float rotZ);
41+
[native] bool GetPlayerObjectRot(int playerid, int objectid, [out] float rotX, [out] float rotY, [out] float rotZ);
42+
[native] int GetPlayerObjectModel(int playerid, int objectid);
43+
[native] bool SetPlayerObjectNoCameraCol(int playerid, int objectid);
44+
[native] bool IsValidPlayerObject(int playerid, int objectid);
45+
[native] bool DestroyPlayerObject(int playerid, int objectid);
46+
[native] int MovePlayerObject(int playerid, int objectid, float x, float y, float z, float Speed, float RotX = -1000.0, float RotY = -1000.0, float RotZ = -1000.0);
47+
[native] bool StopPlayerObject(int playerid, int objectid);
48+
[native] bool IsPlayerObjectMoving(int playerid, int objectid);
49+
50+
const int OBJECT_MATERIAL_SIZE_32x32 = 10;
51+
const int OBJECT_MATERIAL_SIZE_64x32 = 20;
52+
const int OBJECT_MATERIAL_SIZE_64x64 = 30;
53+
const int OBJECT_MATERIAL_SIZE_128x32 = 40;
54+
const int OBJECT_MATERIAL_SIZE_128x64 = 50;
55+
const int OBJECT_MATERIAL_SIZE_128x128 = 60;
56+
const int OBJECT_MATERIAL_SIZE_256x32 = 70;
57+
const int OBJECT_MATERIAL_SIZE_256x64 = 80;
58+
const int OBJECT_MATERIAL_SIZE_256x128 = 90;
59+
const int OBJECT_MATERIAL_SIZE_256x256 = 100;
60+
const int OBJECT_MATERIAL_SIZE_512x64 = 110;
61+
const int OBJECT_MATERIAL_SIZE_512x128 = 120;
62+
const int OBJECT_MATERIAL_SIZE_512x256 = 130;
63+
const int OBJECT_MATERIAL_SIZE_512x512 = 140;
64+
65+
const int OBJECT_MATERIAL_TEXT_ALIGN_LEFT = 0;
66+
const int OBJECT_MATERIAL_TEXT_ALIGN_CENTER = 1;
67+
const int OBJECT_MATERIAL_TEXT_ALIGN_RIGHT = 2;
68+
69+
[native] bool SetObjectMaterial(int objectid, int materialindex, int modelid, string txdname, string texturename, int materialcolor = 0);
70+
[native] bool SetPlayerObjectMaterial(int playerid, int objectid, int materialindex, int modelid, string txdname, string texturename, int materialcolor = 0);
71+
72+
[native] bool SetObjectMaterialText(int objectid, string text, int materialindex = 0, int materialsize = OBJECT_MATERIAL_SIZE_256x128, string fontface = "Arial", int fontsize = 24, bool bold = true, int fontcolor = 0xFFFFFFFF, int backcolor = 0, int textalignment = 0);
73+
[native] bool SetPlayerObjectMaterialText(int playerid, int objectid, string text, int materialindex = 0, int materialsize = OBJECT_MATERIAL_SIZE_256x128, string fontface = "Arial", int fontsize = 24, bool bold = true, int fontcolor = 0xFFFFFFFF, int backcolor = 0, int textalignment = 0);
74+
75+
[native] bool SetObjectsDefaultCameraCol(bool disable);

0 commit comments

Comments
 (0)