#gemrb@irc.freenode.net logs for 6 Nov 2011 (GMT)

Archive Today Yesterday Tomorrow
GemRB homepage

[00:01:13] <-- Kiranos has left IRC (Ping timeout: 245 seconds)
[00:01:27] --> Kiranos has joined #gemrb
[02:44:02] <-- brad_a has left IRC (Quit: brad_a)
[03:15:21] <-- Maighstir has left IRC (Quit: .)
[04:12:19] --> Yoshimo has joined #gemrb
[04:17:54] <-- Yoshimo has left IRC (Quit: Yoshimo)
[06:19:42] --> brad_a has joined #gemrb
[06:21:01] <-- brad_a has left IRC (Client Quit)
[10:33:57] --> Yoshimo has joined #gemrb
[11:35:13] --> SiENcE has joined #gemrb
[12:02:43] --> Maighstir has joined #gemrb
[13:31:44] --> lynxlynxlynx has joined #gemrb
[13:31:45] <-- lynxlynxlynx has left IRC (Changing host)
[13:31:45] --> lynxlynxlynx has joined #gemrb
[13:31:45] --- ChanServ gives channel operator status to lynxlynxlynx
[13:54:12] <-- gembot has left IRC (Ping timeout: 240 seconds)
[13:54:31] --> gembot has joined #gemrb
[13:59:29] <-- gembot has left IRC (Ping timeout: 252 seconds)
[14:12:36] --> gembot has joined #gemrb
[16:54:16] --> barra_home has joined #gemrb
[17:13:25] <CIA-44> GemRB: 03lynxlupodian * ra123d4d5e28f 10gemrb/gemrb/core/Scriptable/Actor.cpp: always restore all spells if the rest was longer or equal to 8h
[18:23:00] --> brad_a has joined #gemrb
[18:23:45] <-- brad_a has left IRC (Client Quit)
[18:29:38] --> brad_a has joined #gemrb
[18:29:48] <brad_a> ug… so hung over.
[18:31:21] <Yoshimo> found a tiger in your room? ;)
[18:33:33] <brad_a> I would have rather that then this headache i have now : &
[18:34:40] <brad_a> and G3 is still down… need to post new iOS release
[18:36:34] <brad_a> damn you germans and your fine oktoberfest lager
[18:37:06] <lynxlynxlynx> you're in yourope?
[18:38:31] <brad_a> I wish. i guess i should correct myself and say german style beer since it wasnt brewed there
[18:58:44] <-- Yoshimo has left IRC (Quit: Yoshimo)
[19:06:42] --> Yoshimo has joined #gemrb
[21:42:40] <lynxlynxlynx> silly wild magic
[22:27:41] <-- SiENcE has left IRC (Ping timeout: 240 seconds)
[22:34:42] --> chiv has joined #gemrb
[22:39:32] <-- barra_home has left IRC (Read error: Connection reset by peer)
[22:46:31] --> joneirik has joined #gemrb
[22:47:53] <-- lynxlynxlynx has left IRC (Remote host closed the connection)
[23:03:52] <chiv> I've started working on geting store to bag selling working, but I'm needing to add stuff to the core :/
[23:04:27] <fuzzie> hmm, shouldn't be necessary to add anything to stuff beyond the GUIScript layer?
[23:06:02] <chiv> the code seams heavily geared for only having one store open
[23:06:06] <Yoshimo> this feels weird, the todo on gemrb.org is growing constantly, and most commits are for chivs stuff :D
[23:06:29] <chiv> are they? not my intention to add work...
[23:06:54] <fuzzie> chiv: well, the GUIScript does GetCurrentStore everywhere, but you can just make it call GetStore on the game data if an optional store param is passed, i hope
[23:07:14] <chiv> that is what i was thinking
[23:07:36] <fuzzie> and btw the current store *must* be the actual store not the bag, but i assume that is the easiest way to do it anyway.
[23:07:39] <Yoshimo> chiv, just an impression , i could be wrong too , and even if im not. Doesnt matter ;)
[23:09:23] <chiv> currently it appears to find the correct store when given a bag name, so I can probably avoid problems from that
[23:10:54] <Yoshimo> what is all this bag and store talking about?
[23:11:55] <chiv> well, originally you can enter a store and sell the contents of a gem bag, but you cant in gemrb
[23:13:17] <chiv> which it should be capable of doing in theory, but the functions arent available to the gui script
[23:16:51] <tomprince> fuzzie chiv: I had stated to implement stores as proper python objects, but I ran into the issue that we delete the store object when we save it.
[23:18:02] <tomprince> I saw two options for representing the store to python.
[23:18:35] <tomprince> 1) Raw pointer, but that gets invalidated when switching games.
[23:18:51] <tomprince> 2) string, which causes a string map lookup on every access.
[23:19:42] <chiv> I was just going to add a couple extra gui funtions to manipulate the internal stores...
[23:19:59] <tomprince> chiv: Like I mentioned before, I am quite happy to write C++/python interface code, to get more of the logic into python and out of GUIScript.cpp
[23:20:23] <tomprince> The only reason more of it isn't, is that people wrote just enough to get things to work.
[23:21:57] <chiv> well, from what i've been able to understand, enterstore and leavestore just need to be extended to allow a specific store rather than just the current one
[23:23:30] <-- Yoshimo has left IRC (Quit: Yoshimo)
[23:23:54] <chiv> so instead of every store function relying on CurrentStore, the guiscript should specify the desired store each time
[23:24:56] <chiv> but I wouldnt want to start doing that if there is a different plan :)
[23:28:30] <chiv> but the current way would work, its just been 'clipped' for want of a word
[23:34:27] <tomprince> I know not everybody agrees with me, but I'd like the python interface be as functional an pythonic as possible.
[23:35:57] <tomprince> The original interface to python passed ids (and pairs of ids) around evrywhere, but now there are objects for many things.
[23:36:25] <tomprince> What I'd really like is for GUIScript to just be a bridge between C++ and python, rather than having all the logic it currently has.
[23:36:38] <chiv> can you give me an example? I'm still learning the python part
[23:37:30] <chiv> oh as in, just passing commands and values back and forth?
[23:39:13] <tomprince> Well, if you look at the docstrings of all the commands, the things that work on controls look like 'SetBufferLength(WindowIndex, ControlIndex, Length)'
[23:39:37] <tomprince> but is now called as control.SetBufferLength(Length)
[23:40:00] <tomprince> And I'd rather do the same type of things for stores.
[23:42:02] <tomprince> So that you would do "store = GetStore('store-name')"
[23:42:08] <tomprince> and then do stuff with store.
[23:42:41] <chiv> actually, that is exactly the thing I was just trying to add :)
[23:43:54] <chiv> but I doubt I can do it that well
[23:44:11] <tomprince> What you should do is write the python code you would ideally like to have, and then I can write the plumbing so that the code works.
[23:44:38] <tomprince> fuzzie brad_a: Do you think it would be an issue to keep stores open indefinitely?
[23:45:25] <brad_a> i haven't a clue :) i'm ignorant of what that would mean
[23:46:42] <tomprince> It's a memory use issue. Right now, whenever we write out a store, we delete it, but I am suggesting it keeping it open.
[23:47:33] <brad_a> well how much memory are we talking here?
[23:48:01] <chiv> a store is just a list of resrefs and quantities isnt it?
[23:48:09] <brad_a> im already pushing the limits of a first gen ipad
[23:48:41] <chiv> i would have though gfx and sound would be the much bigger killer
[23:50:01] <brad_a> well if its just data its probably not a problem
[23:50:18] <brad_a> for me any way
[23:50:56] <brad_a> i guess fixing openal probably reduced memory ussage on ios massively
[23:51:37] <tomprince> Yes, it is probably orders of magnituted smaller than largest memory hogs.
[23:53:33] <brad_a> i feel like ios users will likely want to use TTF fonts anyway which can save a few megs of memory if they use just a couple of different fonts and reduce the glyph range to only what is needed
[23:53:45] <brad_a> well mobile users not just ios
[23:59:00] <chiv> tomprince: i believe the method you described above would be all anyone would need, but it would be nice if instead of one giant cryptic ChangeStoreItem function, it was simplifed to store.buy, store.identify etc
[23:59:42] <brad_a> that sounds like a fine idea to me
[23:59:57] <tomprince> So, prototype something in python, using functions like that, and I'll see about implementing it.