aboutsummaryrefslogtreecommitdiffstats
path: root/src/gameplay.cpp
diff options
context:
space:
mode:
authorClyne Sullivan <tullivan99@gmail.com>2015-10-08 09:10:08 -0400
committerClyne Sullivan <tullivan99@gmail.com>2015-10-08 09:10:08 -0400
commit3120be4f673c3e106c47ee250ca02179bacec52f (patch)
treee3f8fdcf70e40fdf3320b3f3bad5d392e4149160 /src/gameplay.cpp
parent281da1f81b1eef9e05e881e12d986b6b45ce8696 (diff)
improved inventory, debug flags
Diffstat (limited to 'src/gameplay.cpp')
-rw-r--r--src/gameplay.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gameplay.cpp b/src/gameplay.cpp
index b6b939a..a690203 100644
--- a/src/gameplay.cpp
+++ b/src/gameplay.cpp
@@ -31,6 +31,12 @@ int giveTestQuest(NPC *speaker){
return 0;
}
+int giveStuff(NPC *speaker){
+ ui::dialogBox(speaker->name,"Take my stuff you ugly whore");
+ player->inv->addItem(SWORD_ITEM,1);
+ return 0;
+}
+
void initEverything(void){
unsigned int i;
@@ -59,5 +65,6 @@ void initEverything(void){
NPCp(entity[1])->addAIFunc(giveTestQuest);
for(i=0;i<entity.size()+1;i++){
entity[i]->inWorld=test;
+ if(entity[i]->type==NPCT&&i>1)NPCp(entity[i])->addAIFunc(giveStuff);
}
}