Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Script Help Custom item and Give Item script help
Obliviator27 Offline
Posting Freak

Posts: 792
Threads: 10
Joined: Jul 2011
Reputation: 66
#2
RE: Custom item and Give Item script help

(12-29-2011, 09:19 PM)jssjr90 Wrote: Ok so I have a custom item that I have modified, I turned one of the entities from the game, "Note_generic1" into a puzzle item though the model editor, saved it to its own folder with its required recourse's. I also have its own item picture. But I come across 2 problems.

One of my problems is that when I put the new item in the game, it does not have its glow around the object, it acts like a static object. How can I make it to where when I want to pick up it gives me that custom item in my inventory?

Also how to I use Give Item script properly? I have tried giving the player the custom item from the start. This is part of the script:
//
GiveItem("note_generic", "note_generic", "Funeral Bill", note_generic.png, 1);

But it comes up with errors saying this:
note_generic is not declared.

It also states in the function that the object does not half to be in the world.

Can anybody help me out on this? This is the one thing im truly stumped on, im also the one working on that custom story "The Hands That Resist Him" So if anybody can help me out on these 2 problems I would be grateful.



As far as your first issue goes, you need to have the .ent file altered in the ModelEditor in order to make it an item (Found under User Defined Variables) Not sure if you've done this already, but it doesn't hurt to suggest such a thing.

Second issue is simply putting quotation marks around note_generic.png. It'll then look for a phrase instead of a variable in the script.


12-29-2011, 09:26 PM
Find


Messages In This Thread
RE: Custom item and Give Item script help - by Obliviator27 - 12-29-2011, 09:26 PM



Users browsing this thread: 1 Guest(s)