Jump to content

Cipscis

Premium Member
  • Posts

    1103
  • Joined

  • Last visited

Everything posted by Cipscis

  1. As far as I know there aren't any functions for looking within an inventory unless you know exactly what you're looking for. As with previous games, you'll need to wait for the script extender before you'll be able to iterate through an inventory. Cipscis EDIT: Generally, if it didn't need to be done via script in Skyrim, there won't be a native function for it. Anything involving the internals of inventories would have been handled straight be the engine, so there was never a need for a native Papyrus function to walk through inventory items in a container. Cipscis
  2. The scripting language used in Fallout: New Vegas isn't used in Skyrim. Instead, Skyrim uses an entirely new language called Papyrus. I recommend you take a look at the wiki's scripting reference before you try to write any scripts. Cipscis
  3. I'm not sure what you mean by "what said ObjectReference is called". An ObjectReference is basically a pointer to your base form (a Furniture form, in this case) that also contains some extra data, like rotational data. P.S. That "Self" syntax isn't required, although it will compile and work perfectly. I expect, although I haven't tested this, that the Papyrus compiler is good enough to optimise either of these examples just as well, but they're both functionally identical: Self.Disable() Disable() Cipscis
  4. Found it - Class #1 - Doing something Cipscis
  5. That should do the trick... If you script is the same as the one above, you could try extending Actor instead of ObjectReference, although that's just a guess. Cipscis
  6. I still think it's really strange that you get an EOF error at all... Maybe there's some funny extra character in there that's not being displayed by your text editor? If you write it out again from scratch, does the same thing happen? Cipscis
  7. Could you post the scripts you have at the moment? Do they all compile? If not, what errors does the compiler give? If they do compile, what happens when you try to teleport? Cipscis
  8. From where are you trying to get the type of an item? So long as you can get a handle on the reference itself, you should be able to use GetBaseObject to find its base object, although I'm not sure how that would work with filled soul gems. I believe those base objects may be generated by the engine in-game, which is probably why they're fundamentally different to filled soul gems that are found. It's possible that they maintain the same base type, and when they change inventory and a copy is made (if I remember correctly, that's how it works) they are restored to their previous state. Native functions don't have a definition in Papyrus - they are handled by the engine itself. Cipscis
  9. omega2008 is right about the issue, have a look here for a longer explanation - EditorIDs in Papyrus Oh, and for omega2008, all actors can be activated - you just have to add an OnActivate event to your script and it will work. Cipscis
  10. Take a look at this for a longer description of the issue - EditorIDs in Papyrus Cipscis
  11. I've just edited the Notepad++ Setup page, and hopefully it's a bit clearer now. Cipscis
  12. The category pages on the wiki make for good lists. For example: Category:Papyrus and Category:Events Cipscis EDIT: Also note that the console/condition system still uses the old language, including some of the old functions, and a few of their documentation pages have a link to the Papyrus equivalent. Cipscis EDIT: You'll probably find this page very useful, too - Differences from Previous Scripting Cipscis
  13. I've got one tutorial up and another on the way on cipscis.com, although neither of them are introductory tutorials. I saw WillieSea (I think) post a link earlier today to a tutorial he'd written, but I haven't found it again just yet. I'll put a link here if I find it before someone else mentions it. Cipscis
  14. Assuming that was you, I've received your email. I'll try to check it out when I can :) Cipscis
  15. How big is it at the moment? If you send it my way I'll try to find the time to take a look at it, once I get home so I have access to the Creation Kit again. Cipscis
  16. You're missing parentheses after Game.GetPlayer: Scriptname InsertSpellName extends ObjectReference {The} Spell Property InsertSpellName Auto if (Game.GetPlayer().HasSpell(InsertSpellName) == false) Game.AddSpell(InsertSpellName) endIfAlso, note that I've changed "== 0" to "== false". We have proper "bool" types now, so even though yours would work due to automatic casting, using "false" is more semantically correct. Cipscis
  17. Yeah, exactly... If I were you, I'd probably add a bunch of extra events, each containing debugging functions, to see what I can get out of the script as it's currently set up. Cipscis EDIT: Take a look here for some good debugging advice - Having Papyrus trouble? Here are some things to try Cipscis
  18. Oh, right. I find it surprising that the OnContainerChanged event isn't firing, then. If you've added that debug notification you should at least be able to see that... Have you tried using OnActivate instead? I don't think you should need to, but I'm not sure what the problem is either so I'm just going to throw out a couple of guesses. Cipscis
  19. Do you mean when the player activates it, it isn't being picked up properly? Is that something you've intended? You could try using an OnActivate event instead. It's not quite so appropriate, in this case it do the same job. Cipscis
  20. Hmm, the script is definitely attached to the object that the player needs to pick up, right? Cipscis
  21. The properties have all been set up correctly, I assume? Try adding a Debug.Notification call in there to make sure the code is running. Cipscis
  22. I'd expect something like this to work: ScriptName SetStageOnPickup Quest property QuestToUpdate auto int property QuestStage auto Event OnContainerChanged(ObjectReference akNewContainer, ObjectReference akOldContainer) if (akNewContainer == Game.GetPlayer()) QuestToUpdate.SetStage(QuestStage) endif EndEvent Note that the properties will need to be assigned in the editor. I've written this script for general use, so you can reuse it in a similar scenario if you ever need to. What are you using currently? Cipscis
  23. Make sure, for the autocomplete to work, you've enabled that feature in Notepad++. You can find that in the "Backup/Auto-Completion" tab of the "Preferences" window, available under "Settings". If you look inside "Language" is "Papyrus" displayed near the bottom? It should be automatically used for *.psc files, but for anything else (like scripts you're writing from scratch and haven't saved yet) it'll need to be enabled manually. If your batch file doesn't work, try this instead: "D:\Steam\SteamApps\Common\Skyrim\Papyrus Compiler\PapyrusCompiler.exe" %1 -f="TESV_Papyrus_Flags.flg" -i="D:\Steam\SteamApps\Common\Skyrim\Data\Scripts\Source" -o="D:\Steam\SteamApps\Common\Skyrim\Data\Scripts" Pause On the contrary: if you can't follow the wiki it probably needs editing :) Cipscis
  24. You should be able to manually add the *.pex file. It's also worth noting that any scripts extending actor that override the OnDeath block (which I've assumed you've used) will cause your mod not to work on those actors. At least, I'm fairly certain of this - I'll admit it's not something that I've tested. A better approach, in my opinion, would be to give the player a perk that adds a scripted token to each actor they kill via the "Add Leveled List On Death" (label from memory) type of perk entry. In the token's OnInit block, it could activate the actor to which it's been added, opening their inventory screen. Cipscis
  25. There is no "batch attach scripts" functionality in the Creation Kit. Attaching a script to all actors would also mean that your mod would have compatibility issues with any mod that touched any NPC forms in any way, which is really bad. What, exactly, do you want to achieve? Cipscis
×
×
  • Create New...