Hi! Welcome to the forum for Platinum Arts Sandbox Free 3D Game Maker. I currently have the forums locked as I am attempting to properly update them.

In the meantime please join the new Discord Server!

If you have any questions please e-mail me through the Platinum Arts website.

[Cubescript] Kill player trough trigger; spawn monsters?

Having issues not related to a specific Sandbox game mode? Get help here!
Please also read the rules for support when posting support requests.
Failure to comply with the forum rules may result in your topic being locked without resolution.
Locked
User avatar
kddekadenz
Member
Member
Posts: 423
Joined: July 17th, 2011, 11:02 am
Name: kdd
Contact:

[Cubescript] Kill player trough trigger; spawn monsters?

Post by kddekadenz »

I've already searched the cube 2 wiki, but I couldn't find any solution for my problems:

- What is the command to add or take healthpoints from the player?
- Is there any way to spawn monster constantly after a trigger is activated, and until another one is activated?
Kelgar is an advanced RPG beeing developed in Sandbox
User avatar
Leo_V117
Support Team
Support Team
Posts: 1640
Joined: February 16th, 2010, 8:00 pm
Name: Leo
IRC Username: Leo_V117
Location: That one place...
Contact:

Re: [Cubescript] Kill player trough trigger; spawn monsters?

Post by Leo_V117 »

Answer to the first question, You'll need to create yourself a health code. That would be coded in Cubescript.

However, the Monsters... I'm unsure about.
User avatar
kddekadenz
Member
Member
Posts: 423
Joined: July 17th, 2011, 11:02 am
Name: kdd
Contact:

Re: [Cubescript] Kill player trough trigger; spawn monsters?

Post by kddekadenz »

I use Cube 2 to create it:

- There should be already a health code, but I don't know how it works; EDIT: Forget about this one, I found a solution on the wiki. 'Nap' is a command to kill the player.

- Hopefully someone other give me a answer about the monsters.

- New question: How I can change the mapmodel of the trigger via script? I had made such a script time ago, but unfortunately I chose another solution and I didn't remember the command I used for this :o
Kelgar is an advanced RPG beeing developed in Sandbox
User avatar
wildflower
Member
Member
Posts: 76
Joined: August 11th, 2011, 5:10 am
Name: Sandie

Re: [Cubescript] Kill player trough trigger; spawn monsters?

Post by wildflower »

kddekadenz wrote:- New question: How I can change the mapmodel of the trigger via script? I had made such a script time ago, but unfortunately I chose another solution and I didn't remember the command I used for this :o
I use this in the RPG version of PAS:

Code: Select all

r_script_signal "interact" [
    r_select_trigger self [
        if (strcmp (r_trigger_mdl_get) "objects/torch_cold") [
            r_trigger_mdl "objects/torch"
        ] [
            r_trigger_mdl "objects/torch_cold"
        ]
    ]
]
User avatar
Leo_V117
Support Team
Support Team
Posts: 1640
Joined: February 16th, 2010, 8:00 pm
Name: Leo
IRC Username: Leo_V117
Location: That one place...
Contact:

Re: [Cubescript] Kill player trough trigger; spawn monsters?

Post by Leo_V117 »

Great work, wildflower. Looking forward to what you can accomplish in the future.
User avatar
kddekadenz
Member
Member
Posts: 423
Joined: July 17th, 2011, 11:02 am
Name: kdd
Contact:

Re: [Cubescript] Kill player trough trigger; spawn monsters?

Post by kddekadenz »

@wildflower: Thank you for your reply, but unfortanetely I don't develop SauerCraft in RPG - Mode.
Kelgar is an advanced RPG beeing developed in Sandbox
Locked