Games Support Forums BioWare Info My Account Login Community Sign Up Store
Neverwinter Nights 2 Forums

NWN2: Builders - NWN2 Scripting

Nuova discussione    Invia risposta


    Aggiungi a Le mie discussioni

   Vai alla fine

Autore Placeable Heartbeats
friendlyfire
Game Owner
Profilo: friendlyfireNWN
NWN: SoU
NWN: HotU
NWN 2


Registrato il: 27 apr 2003
Da: UK
Inviato: giovedì, 05 novembre 2009 11:28
I think I may have gone mad, but I decided to give NWN2 one last chance... Reinstalled and patched to 1.23, no expansion packs. Nothing else added, clean install.

Make a simple area and put a placeable down. I give the placeable a heartbeat script:

void main(){
SendMessageToPC (GetFirstPC(), "ticktock");
}

Bake, compile all, save, run. No messages. I can see the placeable, it just does not do anything. I check the properties of the placeable and I can see the script there in the heartbeat event slot. I rename the script to p_<tag>_hb where <tag> is the placeable tag. Nothing.

I add the same script to the area heartbeat. Run. "ticktock", "ticktock", "ticktock".

So do placeables not really have heartbeat events or is there some other trickery to getting them working?
  Profilo: friendlyfire   Invia messaggio a: friendlyfire
ciViLiZed
Game Owner
Profilo: ciViLiZedNWN
NWN 2
NWN 2: MotB
NWN 2: SoZ
Mass Effect PC


Registrato il: 15 feb 2005
Da: Montreal, Quebec, Canada
Inviato: giovedì, 05 novembre 2009 01:09
Is your placeable Static FALSE?
_________________
E.C.Patterson
Gaming Parents Studios

NWN2 mod in production: Trinity - Watch the trailer
  Profilo: ciViLiZed   Invia messaggio a: ciViLiZed
friendlyfire
Game Owner
Profilo: friendlyfireNWN
NWN: SoU
NWN: HotU
NWN 2


Registrato il: 27 apr 2003
Da: UK
Inviato: giovedì, 05 novembre 2009 02:22
Good suggestion, but I have tried both (just rechecked, currently not static).
  Profilo: friendlyfire   Invia messaggio a: friendlyfire
ciViLiZed
Game Owner
Profilo: ciViLiZedNWN
NWN 2
NWN 2: MotB
NWN 2: SoZ
Mass Effect PC


Registrato il: 15 feb 2005
Da: Montreal, Quebec, Canada
Inviato: giovedì, 05 novembre 2009 06:14
Just tested in a brand new mod and HB sendmessage works fine with Static FALSE placeable and not with Static TRUE one.

Are you sure the placeable instance is straight from blueprint, and not converted from environmental? Environmental objects converted back to placeables seem to not always recover all their functionality, including perhaps HBs.
_________________
E.C.Patterson
Gaming Parents Studios

NWN2 mod in production: Trinity - Watch the trailer
  Profilo: ciViLiZed   Invia messaggio a: ciViLiZed
BrianMeyer
Game Owner
Profilo: BrianMeyerNWN 2
NWN 2: MotB


Registrato il: 17 giu 2003
Inviato: giovedì, 05 novembre 2009 06:42
I am using a heartbeat in an iPoint placeable.

Seems to work fine for me. Pretty silly, but it does seem to work fine.

Code:

View Post/Code in separate window


_________________
DungeonEternal PVP PW | Joining a PW
  Profilo: BrianMeyer   Invia messaggio a: BrianMeyer
friendlyfire
Game Owner
Profilo: friendlyfireNWN
NWN: SoU
NWN: HotU
NWN 2


Registrato il: 27 apr 2003
Da: UK
Inviato: giovedì, 05 novembre 2009 07:30
Thank you for your help. Here is how the problem occurs. If I pick a standard placeable and add the script, it fires fine.

If I rightclick in the placeable pallete and chose create blueprint, then add the script to the new blue print's hearbeat slot, then it does not fire (with static set to false).

So it apprears to work for an existing placeable blueprint, but not a new blueprint.
  Profilo: friendlyfire   Invia messaggio a: friendlyfire
Lugaid of the Red Stripes
Game Owner
Profilo: Lugaid of the Red StripesNWN 2


Registrato il: 14 ago 2008
Inviato: giovedì, 05 novembre 2009 07:57
Blueprints shouldn't have anything to do with it, the instance in the area is distinct from any blueprints anyway. I've used heartbeats with custom placeables, even placeables spawned-in via script.

How exactly are you using the placeable?
_________________
The Last of the Danaan - SP Mod
Click Here
  Profilo: Lugaid of the Red Stripes   Invia messaggio a: Lugaid of the Red Stripes
BrianMeyer
Game Owner
Profilo: BrianMeyerNWN 2
NWN 2: MotB


Registrato il: 17 giu 2003
Inviato: giovedì, 05 novembre 2009 09:39
Quote: Posted 11/05/09 19:30 (GMT) by friendlyfire

Thank you for your help. Here is how the problem occurs. If I pick a standard placeable and add the script, it fires fine.

If I rightclick in the placeable pallete and chose create blueprint, then add the script to the new blue print's hearbeat slot, then it does not fire (with static set to false).

So it apprears to work for an existing placeable blueprint, but not a new blueprint.

open in new window, compare line by line to another placeable.

The default is not setting something right basically.
_________________
DungeonEternal PVP PW | Joining a PW
  Profilo: BrianMeyer   Invia messaggio a: BrianMeyer
friendlyfire
Game Owner
Profilo: friendlyfireNWN
NWN: SoU
NWN: HotU
NWN 2


Registrato il: 27 apr 2003
Da: UK
Inviato: venerdì, 06 novembre 2009 10:40
Thanks Brian, the problem was driven from when a new blueprint is created. The default object has 0 hitpoints and regardless of whether it is plot, usable etc, the HB event does not fire unless there is a positive value there.
  Profilo: friendlyfire   Invia messaggio a: friendlyfire

Nuova discussione    Invia risposta

Cosa significano queste icone?
Come posso imparare a usare i forum?

Jump To:

Ricerca nei forum | FAQ sui forum | Archivi dei forum

 

 

  Visit the Official Site | Technical Support
Neverwinter Nights 2 Official Support
Mostra/nascondi

English
Deutsch
Français
Español
Italiano

Mostra/nascondi

5,041,995 Users
291 Online
58 collegati

8,767,906 messaggi nei forum

Nuove discussioni:
1. No Text And Stretched Screen (NWN 1: Linux Version - General Discussion)

2. The language issue - once more w... (Mass Effect 2 General Discussion (No Spoilers Allowed))

3. ToB - Final Battle help (Baldur's Gate II Gameplay (Spoilers!))

4. Problem with Jaheira Romance (Baldur's Gate II Gameplay (Spoilers!))

5. The Cerberus Sym... (Mass Effect 2 General Discussion (No Spoilers Allowed))


L'ora attuale è: (imposta ora)
sab, 21 novembre 2009 03:21