Jump to content

DOWNLOAD MODS

Are you looking for something shiny for your load order? We have many exclusive mods and resources you won't find anywhere else. Start your search now...

LEARN MODDING

Ready to try your hand at making your own mod creations? Visit the Enclave, the original ES/FO modding school, and learn the tricks of the trade from veteran modders...

JOIN THE ALLIANCE

Membership is free and registering unlocks image galleries, project hosting, live chat, unlimited downloads, & more...

How to use CreateFullActorCopy in construction set?


TackyG
 Share

Recommended Posts

Hi im trying to edit this mod to summon a unique named creature but it seems CreateFullActorCopy only for for the player or if its used as a target for the skull of corruption.
May I ask for help here? thanks
sample of the code below (me editing ghost in bottle 2 mod)

The editor ID for the ghost is 'aaaReleasedGhost'

scn aaaBottleGhostBottleScript
ref testy
short button
short step
ref rTemp
string_var s

begin OnActivate player
    
    if player.IsWeaponOut == 0
        Activate
        return
    endif
    MessageBox "Do you want to release a ghost?" "Shatter the bottle" "Cancel"
    set step to 1

end

begin GameMode

    if step == 1
        Set button to GetButtonPressed
        if button > -1
            Set step to 0
            if button == 0
                PlaySound aaaSoundBottleShatter
                let rTemp := GetBaseObject
                let s := sv_construct " of %n" rTemp
                sv_replace "'s Ghost in a Bottle|" s            ; for named we get 'of name'
                sv_replace " of Ghost in a Bottle|" s            ; for no-named    we get nothing 
                let s := sv_construct "Angry Ghost%z" s
                Set rTemp to aaaReleasedGhost.CreateFullActorCopy
                rTemp.SetName $s
                sv_destruct s                
                PlaySound NPCGhostAware
                disable
                DeleteReference
            endif
        endif
    endif

end

Link to comment
Share on other sites

  • 4 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...