ID:264217
 
Problem description:
ive made a window for my inventory list and the thing is that
for some reason i cant send anything in to it using the output proc and i have no idea why.
here is the code:
obj
verb
Get()
set src in oview(1)
usr.contents+=src
usr.UpdateInventory()
Drop()
set src in usr
src.loc=usr.loc
usr.UpdateInventory()



mob
proc
UpdateInventory()
var/items=0
for(var/obj/O in usr)
winset(usr,"inventory","current-cell=[++items]")
usr << output(O,"inventory")
winset(usr,"inventory","cells=[items]")


this is the run-time error i get:


winset: Parameter inventory.current-cell not found.
winset: Parameter inventory.cells not found.


can someone please help...


**dont know if it help but:
newwindow:
inventory.grid:
current cell:1,1
Show lines:Both
is Small icons=true
is a flexible list of entries=true



Well, it looks like you're trying to output to a window rather than a grid, first of all. Second of all, no usr in proc.
In response to Jeff8500
i am outputing it to a grid:
winset(src, "inventory.grid", "current-cell=[items]")
src << output(O, "inventory.grid")
winset(src, "inventory.grid", "cells=[items]")


as the code shoes "inventory" is a grid...

can someone tell what am i doing wrong??
Biond_coder wrote:
(...)
newwindow:
inventory.grid:

Is newwindow your default window or is it a pane used in another window?
In response to Schnitzelnagler
i have two windows:
1)mainwindow
2)inventorylist

1 is my default window and 2 is a window just for my inventory list...i didnt check the "is pane" box because i wanted the client to be able to move around his inventory window...
In response to Biond_coder
If inventory is a grid, then you should be outputting to inventory. If inventory is a window with a grid control that has the ID "grid", then you output to inventory.grid.