[Added in Patch 22] [TEA-SCRIPT] char(1).grabbing

Description: Have any suggestions or new ideas for SMBX-38A? This is a place for you. Good suggestions may appear in future versions of SMBX-38A.
Moderators: Yoshi021, Lx Xzit, 5438A38A, Semi-moderatos, Moderators

Victor ManuelMR
Topic author, Duke
Duke
Avatar
Victor ManuelMR
Topic author, Duke
Duke
Reputation: 42
Posts: 111
Joined: 7 Feb 2018

Post #1by Victor ManuelMR » 1 Sep 2019, 20:15

Add the ".grabbing" property to players [Read Only],if the player is holding an NPC. This value will be the NPC ID the player is holding, otherwise it will be 0


Example: If the player is holding a Key(NPC-31) then the value will be 31. [Char(1).grabbing = 31]

Exemple 3.png


Exemple.png
Exemple.png (9.19 KiB) Viewed 1597 times


Exemple 2.png
Exemple 2.png (8.11 KiB) Viewed 1597 times



The ".grabbing" It would be very useful to create specific NPCs such as an NPC that makes the coins go to the player.


UPDATE :
To use the function :val(Grabbing) = npc(char(1).grabbing).id
Last edited by Victor ManuelMR on 22 Sep 2019, 17:15, edited 3 times in total.
Image
[1.4.5] - Dream Team at The Challenging Portals:
Image

Eri7 M
Non Grata
Non Grata
Avatar
Eri7 M
Non Grata
Non Grata
Age: 19
Reputation: 104
Posts: 376
Joined: 19 Dec 2016
Location: Germany, Bonn
Youtube channel URL Twitter

Post #2by Eri7 » 1 Sep 2019, 23:11

I agree with this suggestion, we need this!
Join the discord server about Nova Projects.
Image

Image

NESTED ERNEST M
Count
Count
Avatar
NESTED ERNEST M
Count
Count
Reputation: 37
Posts: 214
Joined: 23 Sep 2017
Location: Perú, Lima
Website

Post #3by NESTED ERNEST » 22 Sep 2019, 17:01

v(Grabbing)=npc(char(1).grabbing).id
Programming NPCs in SMBX-38A is fun:

ROCKMAN GIF IN SMBX 38A

Image

Victor ManuelMR
Topic author, Duke
Duke
Avatar
Victor ManuelMR
Topic author, Duke
Duke
Reputation: 42
Posts: 111
Joined: 7 Feb 2018

Post #4by Victor ManuelMR » 22 Sep 2019, 17:12

NESTED ERNEST wrote:v(Grabbing)=npc(char(1).grabbing).id

Thank you very much =D
Image
[1.4.5] - Dream Team at The Challenging Portals:
Image


Return to “Ideas & Suggestions”

Who is online (over the past 5 minutes)

Users browsing this forum: 4 guests